In the sever.js file, we have on line 8 as
dotenv.config({ path: "./config/config.env" });
and this throw an error when trying to connect to your database so I want to change it to
require("dotenv").config({ path: "./config/.env" });
which makes it easier to connect to your MongoDB once you have your connection string right.
In the sever.js file, we have on line 8 as dotenv.config({ path: "./config/config.env" }); and this throw an error when trying to connect to your database so I want to change it to require("dotenv").config({ path: "./config/.env" }); which makes it easier to connect to your MongoDB once you have your connection string right.