{"id":43403,"library":"nbe-postgres","title":"nbe-postgres","description":"Small plugin (v0.2.1) that provides a PostgreSQL interface for the Node Blog Engine (NBE). Minimal documentation and no active maintenance. Likely only useful as a legacy adapter for NBE-based projects. No notable alternatives; tied to the NBE ecosystem.","status":"abandoned","version":"0.2.1","language":"javascript","source_language":"en","source_url":"https://github.com/SomeKittens/nbe-postgres","tags":["javascript","postgres","blog","node","engine"],"install":[{"cmd":"npm install nbe-postgres","lang":"bash","label":"npm"},{"cmd":"yarn add nbe-postgres","lang":"bash","label":"yarn"},{"cmd":"pnpm add nbe-postgres","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"PostgreSQL client for Node.js","package":"pg","optional":false}],"imports":[{"note":"Package does not export CommonJS; ESM-only. Also no named exports.","wrong":"const postgres = require('nbe-postgres')","symbol":"default","correct":"import postgres from 'nbe-postgres'"},{"note":"Default export is a class; no named export Postgres exists.","wrong":"const Postgres = require('nbe-postgres').Postgres","symbol":"Postgres","correct":"import postgres from 'nbe-postgres'"},{"note":"init is a static method on the default export, not a named export.","wrong":"const { init } = require('nbe-postgres')","symbol":"init","correct":"import postgres from 'nbe-postgres'; const db = postgres.init(config)"}],"quickstart":{"code":"import postgres from 'nbe-postgres';\nimport { engine } from 'node-blog-engine';\n\nconst config = {\n  host: process.env.PGHOST ?? 'localhost',\n  port: parseInt(process.env.PGPORT ?? '5432'),\n  database: process.env.PGDATABASE ?? 'blog',\n  user: process.env.PGUSER ?? 'postgres',\n  password: process.env.PGPASSWORD ?? ''\n};\n\nconst db = new postgres(config);\nconst articles = await db.getArticles();\nconsole.log(articles);","lang":"typescript","description":"Shows how to create a PostgreSQL adapter instance and fetch articles using the Node Blog Engine plugin."},"warnings":[{"fix":"Consider using a standalone PostgreSQL ORM like Sequelize or Prisma instead.","message":"Package is unmaintained and missing type definitions.","severity":"deprecated","affected_versions":">=0.0.0"},{"fix":"Use default import: `import Postgres from 'nbe-postgres'`","message":"Assuming named exports like `{ Postgres }` will cause runtime errors.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"Enable ESM in your project or use dynamic import: `const postgres = await import('nbe-postgres')`","message":"CommonJS `require()` may fail due to missing default export in CJS.","severity":"gotcha","affected_versions":">=0.0.0"}],"env_vars":null,"search_vec":"'activ':22 'adapt':30 'altern':38 'base':34 'blog':15,46 'document':19 'ecosystem':43 'engin':16,48 'interfac':11 'javascript':44 'legaci':29 'like':24 'mainten':23 'minim':18 'nbe':2,17,33,42 'nbe-bas':32 'nbe-postgr':1 'node':14,47 'notabl':37 'plugin':5 'postgr':3,45 'postgresql':10 'project':35 'provid':8 'small':4 'tie':39 'use':26 'v0.2.1':6","created_at":"2026-06-05T16:59:37.956572+00:00","updated_at":"2026-06-05T16:59:37.956572+00:00","problems":[{"fix":"Run `npm install nbe-postgres`","cause":"Package not installed or missing from node_modules.","error":"Cannot find module 'nbe-postgres'"},{"fix":"Use `import` syntax or dynamic `import()`","cause":"Attempting to use `require()` on an ESM-only package.","error":"ERR_REQUIRE_ESM"},{"fix":"Use `import Postgres from 'nbe-postgres'` instead of `import { Postgres } from 'nbe-postgres'`","cause":"Import statement incorrectly destructured named exports.","error":"TypeError: nbe_postgres_1.default is not a constructor"}],"ecosystem":"npm","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://github.com/SomeKittens/nbe-postgres","github":"https://github.com/SomeKittens/nbe-postgres","docs":null,"changelog":null,"pypi":null,"npm":"nbe-postgres","openapi_spec":null,"status_page":null,"smithery":null,"categories":["database"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-05","next_check":"2026-09-03","install_tag":null}}