/mongoose_tutorial

playing with mongodb and mongoose (node.js)

Primary LanguageCSS

To run:

  • Execute npm install from this directory
  • Execute npm start
  • Navigate to localhost:8000

Routes

  • / : Home
  • /insert : insert document to the mongodb
  • /name : return model name
  • /getid/:id : return the document data by id
  • /adduser : display a form to add user and password to the mongodb
  • /adduser : POST route for creating the user from the form
  • /login : login form for authentication
  • /loginpost : handle the login form (POST route)