This is a client (react) server (Node) API
Modern Full-Stack Starter/Tutorial Using React/Redux/Node/Mongoose.
M - Mongo E - Express R - React N - NodeJS
This is the project files for tecdreams's API Authentication with Node.
-
Phase I - Backend
-
Phase II - Frontend
-
Phase III - Improvements!
- Link Facebook and Google to local Account
- Change localstorage to Session Cookies
- Backend sends cookie after auth
- Cokie is set to be httpOnly
- FrontEnd checks is user is Auth on refresh page or load
$ git clone https://github.com/clio19/NodeAuthAPi
then checkout the branch as follow
$ git checkout 'branch_name'
This project uses async/await it would be best if you use node 10+ after checkout be sure to run
$ npm install
installing using yarn
$ yarn install
To run the project use
$ npm run start-dev
starting the project using yarn
$ yarn start-dev
run unit tests
$ yarn test
genarate code coverage report
$ yarn report
run unit tests with nyc output in terminal
$ yarn nyc
run unit tests with nyc summery report
$ yarn text-report
Check npm updates (Globally)
$ npm i -g npm-check-updates
or
$ npx npm-check-updates
Version | Supported |
---|---|
5.1.x | ✅ |
5.0.x | ❌ |
4.0.x | ✅ |
< 4.0 | ❌ |
File | % Stmts | % Branch | % Funcs | % Lines | Uncovered Lines |
---|---|---|---|---|---|
All files | 100 | 100 | 100 | 100 | |
controllers | 100 | 100 | 100 | 100 | |
users.js | 100 | 100 | 100 | 100 | |
routes | 100 | 100 | 100 | 100 | |
users.js | 100 | 100 | 100 | 100 |