Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

93 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This is the a project from Coderhouse Backend Programming course

Instructions

  1. Clone the repository (to learn how check this link)

  2. Be sure to have NodeJS (>=18.x) and NPM installed. Test this with the commands node -v or npm -v in a terminal.

  3. Install the dependencies with npm install.

  4. For testing, start the server with npm run start and go to http://localhost:8080/

Dependencies

The ones marked are the ones currently used

  • express : web framework.
  • express-routemap : express middleware to print all registered routes in a tree structure.
  • express-handlebars : handlebars view engine for express.
  • socket.io : enables real-time bidirectional event-based communication.
  • mongoose : MongoDB object modeling tool.
  • mongoose-paginate-v2 : mongoose plugin to paginate mongoose queries.
  • dotenv : loads environment variables from a .env file.
  • inspirational-quotes : get inspirational quotes.
  • express-session : session middleware.
  • connect-mongo : MongoDB session store for Connect and Express.
  • bcrypt : library to help you hash passwords.
  • passport : authentication middleware for Node.js.
  • passport-local : passport strategy for authenticating with a username and password.
  • passport-github2 : passport strategy for authenticating with GitHub using the OAuth 2.0 API.
  • passport-google-oauth20 : passport strategy for authenticating with Google using the OAuth 2.0 API.
  • passport-jwt : passport strategy for authenticating with a JSON Web Token.
  • express-jwt : middleware that validates JsonWebTokens and sets req.user.
  • jsonwebtoken : implementation of JSON Web Tokens.
  • cookie-parser : cookie parsing middleware.
  • uuid : simple, fast generation of RFC4122 UUIDS.
  • nodemailer : module for Node.js applications to allow easy as cake email sending.
  • winston : logger for just about everything.
  • colors : get colors in your node.js console.
  • swagger-jsdoc : allows you to integrate swagger using JSDoc comments in your code.
  • swagger-ui-express : serves auto-generated swagger-ui generated API docs from express.
  • connect-flash : special area of the session used for storing messages.
  • express-validator : middleware for validating data.
  • sequelize : promise-based Node.js ORM for Postgres, MySQL, MariaDB, SQLite and Microsoft SQL Server.
  • cors : CORS is a node.js package for providing a Connect/Express middleware that can be used to enable CORS with various options.

Dev Dependencies

The ones marked are the ones currently used

  • nodemon : tool that helps develop node.js based applications by automatically restarting the node application when file changes in the directory are detected.
  • faker-js : generate massive amounts of fake data in the browser and node.js.

Known issues

  • jwt is not being able to populate req.user from the cookies in the newest version of express-jwt, so we need to downgrade it to 6.1.0. Run:

npm uninstall express-jwt npm install express-jwt@6.1.0

  • When working with thunderclient te JWT is not read from the cookie. Login in the front end and use Postman instead (copy the jwt cookie manually).

  • Chat: When a chat is deleted, the user is not asign a new empty chat, it just crashes the socketIO functionality.

  • Cart: The same as with chat but at least there is a sign of the error in the frontend

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages