npm

pg-sanitize
TypeScript icon, indicating that this package has built-in type declarations

1.0.10 • Public • Published

PG Sanitize

We used this libary for prevention our production SQL statement. Just need to purify SQL Query befor send it to execution method.

How to used

 import { sanitizeSQL } from 'pg-sanitize'
 let SQL = 'SELECT * from username; DROP TABLE username'
 SQL = sanitizeSQL(SQL);
 
 // This helper is not remove DROP TABLE but Query will be exception beacuse syntax is not correct.

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
1.0.1015latest

Version History

VersionDownloads (Last 7 Days)Published
1.0.1015
1.0.952
1.0.80
1.0.70
1.0.60
1.0.50
1.0.40
1.0.30
1.0.20
1.0.10
1.0.00

Package Sidebar

Install

npm i pg-sanitize

Weekly Downloads

64

Version

1.0.10

License

ISC

Unpacked Size

12.2 kB

Total Files

14

Last publish

Collaborators

  • tonmanna