|
| 1 | +](doc/images/Quiz_App_REST-API.png) |
| 2 | + |
1 | 3 | # Quiz-App-REST-API-TS-Mongoose
|
2 | 4 | This is Backend - REST API for a Quiz App build using TypeScript and Mongoose.
|
| 5 | +### Backend playlist: [Quiz App Backend](https://www.youtube.com/playlist?list=PLIfcYFqzDXHlHjNyVs5J5KCe6B1NYZ7WK) |
| 6 | + |
| 7 | +## Dependencies: |
| 8 | + |
| 9 | + |
| 10 | + |
| 11 | + |
3 | 12 |
|
4 | 13 | # What you can learn by exploring
|
5 | 14 | - There is JWT authentication in this app
|
6 | 15 | - There is express validator and express error routes
|
7 | 16 | - There is custom error class.
|
8 | 17 | - There is nodemailer used in this.
|
9 | 18 |
|
10 |
| -# How to start? |
| 19 | +## How to Start ? |
11 | 20 | - Step 1: Clone this repository.
|
12 |
| -- Step 2: Run Command - "yarn install" to install all the required packages. |
13 |
| -- Step 3: Add environment configuration details to nodemon.json for development. |
14 |
| -- Step 4: Run Command - "yarn start:dev" to execute this project on localhost. |
| 21 | +- Step 2: To install all the required packages run command: |
| 22 | + ```sh |
| 23 | + yarn install |
| 24 | + ``` |
| 25 | +- Step 3: Add environment configuration details to nodemon.json for development. |
| 26 | +](doc/images/carbon.png) |
| 27 | +- Step 4: Replace `<DATABASE_CONNECTION_STRING>` with appropriate connection string. |
| 28 | +- Step 5: To apply JWT authentication, replace `<ENCRYPTION_SECRET>` with appropriate key. |
| 29 | +- Step 6: To use the emailer functionality, replace `<USER_EMAIL>` with an actual email and enable 2-step Verification on it. |
| 30 | +- Step 7: Visit manage account of the email and search for **App passwords**](<doc/images/Screenshot 2023-10-02 191641.png>) |
| 31 | +and create new app specific password and replace `<USER_PASSWORD>` with that new password. |
| 32 | +- Step 8: Replace `<SERVICE_PROVIDER>` with the service provider you wish to use and in this case **smtp.gmail.com** is used. |
| 33 | +- Step 9: Replace `<SERVER_BASE_URL>` with **localhost:3000** |
| 34 | +- Step 10: To execute this project on localhost run command: |
| 35 | + ```sh |
| 36 | + yarn start:dev |
| 37 | + ``` |
0 commit comments