Setting up MongoDB Atlas was challenging because I couldn’t find the "Create Database" button at first, but I resolved it by following the "Browse collections" option. I also encountered a Git error about dubious ownership, which I fixed by adding the directory to the safe list. Additionally, I faced a MongoDB connection error (ENOTFOUND) due to an incorrect cluster name, which I resolved by updating the connection string with the correct cluster name (obada1.puo2d1d.mongodb.net). Finally, I had an authentication error because I was using a different computer, which caused confusion with the database user. I fixed this by ensuring I was in the correct project and using the right credentials. Overall, this lab helped me understand how to connect a Node.js app to MongoDB, build a REST API, and dynamically display data in a web page using JavaScript.
#update
I faced challenges with MongoDB setup, Git errors, and a MongoClient import issue, which I resolved by following documentation, using a PAT for GitHub, and ensuring correct imports in server.js. Overall, this lab taught me how to connect a Node.js app to MongoDB and build a REST API.
#update
update the structure of the server