MongoDB driver for DeepBase, a reactive nested-object database. Version 3.6.9 is the latest stable release. It stores DeepBase data in MongoDB collections using upsert logic, supports atomic $inc/$dec operations, dot-notation nested updates, and multi-driver setups (e.g., MongoDB primary with JSON backup). Requires the deepbase package as a peer dependency. Well-suited for production applications needing scalability and complex queries, with TypeScript types included.
npm install deepbase-mongodbNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows how to instantiate DeepBase with the MongoDriver, connect to MongoDB, and perform basic get/set operations.
Use import MongoDriver from 'deepbase-mongodb' for ESM, or const MongoDriver = require('deepbase-mongodb').default for CJS.Always provide both database and collection options explicitly.
Verify keys before writing or use transactions/check-exists logic.
Avoid dots in key names, or escape them if necessary.
Use database: 'myapp' instead of base: 'myapp'.
Run: npm install deepbase
Start MongoDB or adjust the url option. For local development: docker run -d -p 27017:27017 --name mongodb mongodb/mongodb-community-server:latest
Use: const MongoDriver = require('deepbase-mongodb').default;Provide a valid MongoDB connection string starting with mongodb:// or mongodb+srv://