pg-parse-float

0.0.1 • Public • Published

pg-parse-float

Restore 'parseFloat' functionailty to node-postgres. Allowing it to return float column types as JavaScript floats.

install

npm install pg-parse-float

use

var pg = require('pg');
require('pg-parse-float')(pg);
 
//now all your floats (float4, float8, numeric) will come back out
//as floats in JavaScript

notes

This can be used as an example of how to extend or override the built in type parsers for other types as well.

There were some discussions around this:

license

MIT

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.0.1
    4,979
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.0.1
    4,979

Package Sidebar

Install

npm i pg-parse-float

Weekly Downloads

2,549

Version

0.0.1

License

MIT

Last publish

Collaborators

  • brianc