#backend with express
to initai npm install
and npm i nodemon
npm i express
create a index.js file and import the exress from express => add "type" : "module" in package.json ,
create the app using express,
adding the port number to port variable
app.listen(port,()=>console.log(the is listening ${port}
))
now in the terminal give start command npm start or nodemon
TO create a model and connect to database
Install mongoose => npm i mongoose INstall dotenv for environment file npm i dotenv and config() import mongoose and mongoose.connect("mongodb+srv://@leoestate.expwuff.mongodb.net/?retryWrites=true&w=majority")
creating models using mongoose
and mvc mesthod creating the file and connecting to each other
Sign up route
//to encrypt us bcryptjs import the bcrypt in auth file