TolgaS92 / node-react-auth

Skeleton for Node and React with authentication

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Getting started

Connecting front end and backend

Adding the database

  • npm i mongoose Mongoose npm
  • npm i -D mongoosejs-cli Mongoose npm cli
  • touch .mongooserc and setup the file to use a db root directory as shown on the cli website
  • npx mongoosejs-cli init to add mongo db setup to application
    • Notice you now have a db folder with models in it
  • npx mongoosejs-cli model:create --name User --attributes name:String,email:String,password:String
  • npx mongoosejs-cli seed:create --name AddUser - to populate users
  • Add bcrypt npm npm i bcrypt
  • Add initial user with Seeds npm run seed

About

Skeleton for Node and React with authentication


Languages

Language:JavaScript 84.5%Language:HTML 8.7%Language:CSS 5.3%Language:Handlebars 1.5%