An open API service indexing awesome lists of open source software.

https://github.com/tea-node-js/tea-rest-plugin-mysql


https://github.com/tea-node-js/tea-rest-plugin-mysql

Last synced: about 1 month ago
JSON representation

Awesome Lists containing this project

README

          

# tea-rest-with-mysql

MySQL & Sequlize as store, Base on tea-rest

## Node version

 >= 8 

## tea-rest version

 >= 8

## Installation
```bash
npm install tea-rest-plugin-mysql --save
```

## Usage
```js
const teaRest = require('tea-rest');
const getter = require('tea-rest-helper-getter');
const assert = require('tea-rest-helper-assert');
const rest = require('tea-rest-helper-rest');
const params = require('tea-rest-helper-params');

teaRest
.plugin(U.teaRestPluginMysql)
.plugin(getter, assert, rest, params)
.start(`${__dirname}/app`, (error) => {
if (error) {
console.error(error);
process.exit();
}
console.info(`Service started at: ${new Date()}`);
});

```