Node.js / Express / Mongodb shopping cart project
- Install scaffolding project (hbs - means Handlebar default template engine)
express shopping-cart --hbs
- Install dependencies
npm install
- Add Bootstrap .css and .js from https://getbootstrap.com/
- Add jQuery
- Install more featured version of Handlebars for express
npm install --save express-handlebars
and setup new app engine - app.set('.hbs', expressHbs(...)) 6. Add https://use.fontawesome.com/ 7.
npm install --save mongoose
- Install Node.js CSRF protection middleware (cookie tokens for HTTP session).
npm install --save csurf
- And for stay login in the system every new request in session (by saving token)
npm install --save express-session
- To handle all user authentication and signup
npm install --save passport
// choiced strategy
npm install --save passport-local
- To encrypt password
npm install --save bcrypt-nodejs
- The flash is a special area of the session used for storing messages
npm install --save connect-flash
- For validate input fields
npm install --save express-validator
- To save shopping goods some specified time in db
npm install --save connect-mongo
- For payment card validation and pay with card https://stripe.com/ (Payment Request API.)