pg-helpers is a lightweight Node.js library (v1.0.0) providing utility functions for querying PostgreSQL databases. It wraps common query patterns such as select, insert, update, and delete, and offers simple connection management via a configuration object. The library is designed for small-to-medium projects that want a thin layer over raw SQL without a full ORM. It uses the 'pg' package as a peer dependency and is released infrequently. Compared to Knex or Prisma, it provides minimal abstraction and is best for developers who prefer writing SQL with some helper shortcuts.
npm install pg-helpersNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows how to set up a pg pool and use query, select, and insert helpers.
Use import syntax or set { "type": "module" } in package.json.Use it as del() or alias it with a different name when importing.
Run 'npm install pg' in your project.
Run 'npm install pg-helpers pg'
Use ES module import syntax: import { query } from 'pg-helpers'