You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: README.md
+41-37
Original file line number
Diff line number
Diff line change
@@ -2,14 +2,14 @@
2
2
3
3
## This repo can be cloned/forked and used as a boilerplate for a node REST API
4
4
5
-
I built this repo to learn how to make a rest api and server. It was created by following [this tutorial](https://www.codementor.io/olatundegaruba/nodejs-restful-apis-in-10-minutes-q0sgsfhbd), and has been expanded on to service the needs of a boilerplate project.
5
+
I built this repo to learn how to make a rest api and server. It was created by following [this tutorial](https://www.codementor.io/olatundegaruba/nodejs-restful-apis-in-10-minutes-q0sgsfhbd), and has been expanded on to service the needs of a boilerplate project. I've also used inspiration from [this awesome dev!](https://github.com/christopherliedtke)
6
6
7
7
The different things you can do with this server:
8
8
9
-
- Controllers - deals with database read/write operations
10
-
- Models - define schemas of objects in collections the database
11
-
- Routes - defines the API routing for controller functions
12
-
- Middlewares - helper filesand methods
9
+
- Controllers - deals with database read/write operations and logic.
10
+
- Models - define schemas of objects in collections the database.
11
+
- Routes - defines the API routing for controller functions.
12
+
- Middlewares - helper files, utils and methods. Basically anything that isn't done by a controller.
13
13
14
14
### Installing & config
15
15
@@ -25,7 +25,7 @@ The different things you can do with this server:
25
25
26
26
2. Add a `JWT_SECRET` to the `.env` file
27
27
28
-
3. Start the server with nodemon: `npm start`
28
+
3. Start the server with nodemon: `npm start`. Currently the default port for the server is `5000` and this can be set in the `.env`. This is to prevent clashes when running the server and clients in dev locally.
29
29
30
30
4. Restart running server by typing: `rs`
31
31
@@ -41,70 +41,74 @@ The different things you can do with this server:
0 commit comments