https://github.com/summerfans/koa2-api-ts-boilerplate
koa2 typescript
https://github.com/summerfans/koa2-api-ts-boilerplate
api-server koa2 nodejs postgresql redis typescript
Last synced: over 1 year ago
JSON representation
koa2 typescript
- Host: GitHub
- URL: https://github.com/summerfans/koa2-api-ts-boilerplate
- Owner: SummerFans
- License: mit
- Created: 2016-10-08T09:33:50.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2018-03-01T15:25:38.000Z (over 8 years ago)
- Last Synced: 2023-09-11T08:32:09.594Z (almost 3 years ago)
- Topics: api-server, koa2, nodejs, postgresql, redis, typescript
- Language: TypeScript
- Homepage:
- Size: 20.5 KB
- Stars: 7
- Watchers: 1
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# koa2-api-ts-boilerplate
project based on KOA2 framework to develop API services
## include
- [x] Koa2
- [x] Typescript
- [x] Postgresql
- [ ] Redis
- [x] Doc (apidoc)
- [ ] Testing
## Structure
```
├── src
│ ├── config # config
│ │ ├── env # environment
│ │ │ ├── development.ts
│ │ │ └── production.ts
│ │ ├── common.ts
│ │ ├── index.ts
│ ├── modules
│ │ ├── init
│ │ │ ├── controller.ts # controller
│ │ │ └── router.ts # router
│ │ └── article # article example
│ │ ├── controller.ts
│ │ └── router.ts
│ ├── models # data model
│ │ └── article.ts # article model
│ ├── middleware
│ │ └── auth.ts # auth
│ │ └── error.ts # error
│ └── utils
│ └── db.ts # database config
│ └── index.ts # util
└── tsconfig.json # tsc configure
```
### Command
```
npm run start //run service
npm run build //build js
npm run watch //watch service
npm run docs //build the document
```