Skip to content

Latest commit

 

History

History
19 lines (15 loc) · 700 Bytes

README.md

File metadata and controls

19 lines (15 loc) · 700 Bytes

Node.js Example: Counting MongoDB documents

An example of counting the number of documents in the restaurant collection

Getting Started

  1. Change the value of variable url in server.js to the address of your MongoDB Atlas Cluster. Modify the creditentals of your Database User and Database Name.

MongoDB Atlas Connect URL

  1. Change the value of varibale dbname in server.js to your DB name
  2. You need a collection named restaurant in dbname with a few documents in it.

Installing App Dependencies

npm install

Run App (and see results)

npm start