A No-SQL database.
Creating In Cloud
- https://www.mongodb.com/products/platform/atlas-database
- Create the database local user and password
- Copy the connection string
- Allow any device to access this database (For testing purposes)
- Make an .env storing your
MONGO_USERNAME
andMONGO_PASSWORD
import mongodb from 'mongodb'
const MongoClient = mongodb.MongoClient
const mongo_username = process.env["MONGO_USERNAME"]
const mongo_password = process.env["MONGO_PASSWORD"]
const uri = "<connection string you copied>"
// Example: const uri = "mongodb+srv://${mongo_username}:${mongo_password}@cluster0.jae3r.mongodb.net/?retryWrites=true&w=majority&appName=Cluster0"
Installation NodeJS
npm install mongodb