MongoDB
Vanilla Mongo and Mongoose examples. Mongoose provides a convenient way to make and enfore schemas for Mongo. A schema is a design of a database document--the different fields and their data types.
- [] Go to
server-vanilla-mongo.js
and follow the instructions in the comments in the middle of the file. - []
(Optional)
Go toserver-mongoose.js
and learn how to use Mongoose to enforce consistency in what fields all documents in a collection must have.