mongoose-dbA mongoosedb adapter for use with Node apps at Bouncing Pixel. Implements necessary functions for use with
passport-auth. Can generate a Mongo based session store if desired.
- NodeJS 6 LTS
- MongoDB 3.x
- Mongoose v4.7.x
ConfigurationThis module, like many other
@bouncingpixelmodules, relies on nconf. The following configuration keys should be defined to use this module:
useMongoClientoptions are no longer need since the mongo client is enabled by default.
Using mongoose-dbBe sure to add
mongooseto your app before using this module. The must be initialized before using. The
initfunction will make the connection to mongo. The
initfunction can take an optional path to the models directory and pre-load all models.
init(): Promise getSessionStore(expressSession: ExpressSession): MongoStore