Node.js Koa Boilerplate is an project that allows you to start new node.js project from scratch.
This project uses TypeScript. You can review Flow and Javascript versions.
Use these steps to install project
- Create Postgres databse (you can use official Docker container)
- Add environment variables
- npm i
- npm start
This boilerplate contains such folders:
- /src - main sources folder.
- /src/constants - app constants.
- /src/controllers - contain controllers that receives requests from routes, executes business logic via services and returns responses to client.
- /src/db - contain scripts to setup and manage database
- /src/middleware - app middlewares
- /src/entities - database entities
- /src/services - services contains logic to manage database, execute requests to other servers, change application behabior, and etc.
- /src/app.ts - app configuration
- /src/index.ts - contain main scripts that configures and run server
- /test - contains tests for controllers, services and other parts of application.
- start - run node.js server
- serve - run builded files
- build - build project
- Fork it!
- Create your feature branch:
git checkout -b my-new-feature
- Commit your changes:
git commit -am 'Add some feature'
- Push to the branch:
git push origin my-new-feature
- Submit a pull request :D
Vlad Morzhanov
Copyright (c) 2018 Vlad Morzhanov. You can review license in the LICENSE file.