mongo-driverify
v1.0.4
Published
Simple basic driver for node and mongo db combination
Readme
mongo-driver
Simple basic driver for node and mongo db combination
Installation:
npm install mongo-driverify --saveSetup your Mongo Driver
const MongoDriver = require('mongo-driverify');
MongoDriver.MongoDBManager.configure({
connectionString: 'mongodb+srv://XXXX:[email protected]/XXXX',
hasCert: false,
certPath: '',
dbName: 'XXXX'
});Usage:
Get driver instance
const driver = MongoDriver.MongoDBManager.getInstance();Insert documents
await driver.insertDocProm({ 'id': 1, 'string': 'abc', 'number': 10 }, collectionName);Fetch documents
await driver.getDocumentsByProm(collectionName, { 'id': 1 });Complete Documentation
Click here to checkout complete documentation or View Documentation page here
Features:
- Supports Insert, Fetch, Delete, Update document etc functionality.
- Simple light weight driver for your mongodb.
- Only 1 dependency.
