Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

pg.js

Package Overview
Dependencies
Maintainers
1
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pg.js

node-postgres without the bindings

  • 3.4.2
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2K
decreased by-10.24%
Maintainers
1
Weekly downloads
 
Created
Source

node-postgres-pure

The exact same node-postgres module without any of the C/C++ stuff. If you're just using the pure JavaScript bindings, there's really no reason to wait for the native stuff to compile.

install

npm install pg.js

use

//exact same code, you can just change the string
//in your requires from pg to pg.js and you're done
var pg = require('pg.js')

pg.connect(function(err, client, release) {
  if (err) throw err;
  client.query('SELECT NOW()', function(err, res) {
    release()
    if (err) throw err;
    console.log(res.rows[0])
  })
})

how it works

I pull in the node-postgres repo and delete the /src folder and the .gyp file.

Then I publish the same code to npm as pg.js. So easy.

license

MIT

FAQs

Package last updated on 10 Aug 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc