A boilerplate/template for building RestAPI's using NodeJS, TypeScript, Express and Mongoose
- Clone the project https://github.com/kyooowe/ecommerce-portal.git
- Open terminal
npm i
or
yarn install
Create .env file in root folder and Add the following
PORT=yourChoicePort
TOKEN_KEY=yourChoiceTokenKey
MONGO_DB=yourMongoDbConnection
- NoSQL database using MongoDB
- JWT Authentication
- Password encryption using Bcrypt
- Cron Job
- Testing: automated testing using Jest
- Dependency management with NPM
- Environment variables using cross-env and dotenv
- CORS
- Git hooks using hustky and lint-staged
- Linting using prettier, eslint and tslint
- Compression using GZIP
- Middleware HTTP Protection using Helmet
- Email sender using NodeMailer
- Src
- Config (project configurations)
- Controller (project controllers/services)
- Helpers (project custom helpers)
- Inteface (global interface in project)
- Middleware (projects custom middleware)
- Models (mongoose schemas)
- Routes (projects routes)
- Create your own interface in inteface (Folder)
- Create schemas in models (Folder)
- Add your services in controller (Folder)
npm run start
npm run test
npm run lint
Incoming
- Socket.io
- Logger