/rx-models

Models server with REST API. 模型驱动的后端,通过通用JSON接口查询业务模型数据。

Primary LanguageTypeScript

Nest Logo

A progressive Node.js framework for building efficient and scalable server-side applications.

NPM Version Package License NPM Downloads CircleCI Coverage Discord Backers on Open Collective Sponsors on Open Collective Support us

Description

Nest framework TypeScript starter repository.

Installation

要使用TypeORM CLI创建Models,需要全局安装TypeORM:

$ npm install -g ts-node
$ npm install typeorm -g  

安装本项目

$ npm install

配置数据库

cp ormconfig-example.json ormconfig.json

更新数据库配置 ormconfig.json

...
  "username": "root",
  "password": "",
  "database": "rxdrag",
...

生成数据库 (需要执行两次)

$ npm run typeorm migration:run  

Running the app

# development
$ npm run start

# watch mode
$ npm run start:dev

# production mode
$ npm run start:prod

Test

# unit tests
$ npm run test

# e2e tests
$ npm run test:e2e

# test coverage
$ npm run test:cov

Support

Nest is an MIT-licensed open source project. It can grow thanks to the sponsors and support by the amazing backers. If you'd like to join them, please read more here.

Stay in touch

License

Nest is MIT licensed.