Skip to content

A starter for my Express projects with token-based auth

License

Notifications You must be signed in to change notification settings

meghprkh/express-auth-starter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Express Auth Starter

Build Status

This is a starter/boiler-plate I use for creating express apps. It gives a minimal REST API with token-based authentication

Setting Up

npm i

Running in dev mode

Please make sure the frontend server is also running in dev mode

npm start

The API will now be available at http://localhost:3000/api

Running in prod mode

Please build the frontend and copy the files from the dist folder there to the public folder here. Then run the following command

npm run prod

Now go to http://localhost:3000/

Libraries & Devtools Used

  • ExpressJS: The most popular NodeJS microframework
  • Sequelize: A good ORM for NodeJS
  • SQLite: A good small database that is used so that much setup is not required for trying this out. In production I switch to MariaDB
  • JWT: A standard for signing JSON tokens and verifying them
  • Nodemon: A good tool for development and keeping your server running forever
  • Morgan: Simple logger for ExpressJS
  • ESLint: The source code linter used to notice mistakes and a few styling rules
  • Postman: Tool used for testing the API while development

License

The code is provided under the ISC license

About

A starter for my Express projects with token-based auth

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published