Skip to content

Commit

Permalink
Merge pull request #1 from baohangxing/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
baohangxing authored Apr 13, 2020
2 parents f6795a9 + cfc483f commit 3887070
Show file tree
Hide file tree
Showing 64 changed files with 6,833 additions and 166 deletions.
2 changes: 2 additions & 0 deletions server/app.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
const Koa = require('koa');
const app = new Koa();
const cors = require('koa2-cors');
const views = require('koa-views');
const json = require('koa-json');
const onerror = require('koa-onerror');
Expand All @@ -25,6 +26,7 @@ onerror(app);
app.use(bodyparser({
enableTypes: ['json', 'form', 'text']
}));
app.use(cors());
app.use(json());
app.use(logger());
app.use(require('koa-static')(__dirname + '/public'));
Expand Down
9 changes: 9 additions & 0 deletions server/config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
module.exports = {
mysql: {
'host': 'localhost',
'user': 'root',
'password': 'Bao522124.',
'database': 'segment',
'port': '3306'
}
};
Loading

0 comments on commit 3887070

Please sign in to comment.