A lightweight TypeScript-first MongoDB extension providing typed helpers and utilities for common MongoDB operations. Current stable version 0.3.5, released monthly. Designed for type-safe database interactions with minimal overhead, offering schema validation stubs and query builders. Differentiates from Mongoose by focusing on direct MongoDB driver integration with TypeScript types rather than full ODM features.
npm install mongodb-extensionNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows connecting to MongoDB and using QueryBuilder for type-safe queries.
Update code to treat query as plain object directly passed to find()
Replace validateSchema() calls with validate()
Initialize a MongoClient first, then pass it to connect()
Use import { connect } from 'mongodb-extension'Ensure 'mongodb-extension' is installed and 'module' in tsconfig is set to 'node' or 'node16'