Apply for Zend Framework Certification Training

NodeJs






Step 1) npm i mongoose
Step 2) create folder config
In config folder create mongoose-connect.js 
And type these code 
 
const mongoose = require('mongoose')
mongoose.connect("mongodb://0.0.0.0:27017/company",{});
const usersSchema = {
    firstname:String,
    lastname:String,
    email:String,
    mobileno:String,
    password:String
};
const company = mongoose.model('users',usersSchema);
module.exports = company;

< First Getting Started With CodeIgniter URL Routing >



Ask a question



  • Question:
    {{questionlistdata.blog_question_description}}
    • Answer:
      {{answer.blog_answer_description  }}
    Replay to Question


Back to Top