Parse and pass the request to service layer and return response to client Request and response object must be kept inside this layer.
Layer where business logic must be implimented. and data must be sent to data access layer.
Layer where DB is accessed. must have the exclusive rights to accesss the database a n make changes to DB
-
learn difference between devDependencies and dependencies and use them accordingly
-
Use any linter to enfore coede standards and improve code quality
-
Use lowerCamelCase for variables
-
Use uppercase from string constants and enum keys
-
Need to prefix _ for unused, but unavoidable variables
function (_param1, param2)
-
Avoid unnecessary variable declaration. Use const when read-only
-
Avoid var declarations
-
Use single qoutes rather than double quotes
-
Prefer templates in strings (especially in multi-line strings)
-
Use promise/async-await
-
Write modular code
-
Use Arrow functions
-
Use === rather than ==
-
Write synchronous code with extra care
-
Write reusable codes as modules