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

1.0.9 • 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.

Readme

Keywords

none

Package Sidebar

Install

npm i pg-sanitize

Weekly Downloads

5

Version

1.0.9

License

ISC

Unpacked Size

8.91 kB

Total Files

12

Last publish

Collaborators

  • tonmanna