Updated API docs to fix documentation errors on github pages which is the target of the documentation. The main culprit was not having cors enabled to handle the same origin policy of the browsers. With the koa-cors package now enabled this will work perfectly.

This commit is contained in:
Mark Beamer Jr 2018-04-08 02:13:27 -04:00
parent 7d55981ad8
commit 47890ad56e
8 changed files with 11 additions and 424 deletions
server

View file

@ -1,4 +1,5 @@
import bodyParser from 'koa-bodyparser';
import cors from '@koa/cors';
import Koa from 'koa';
import logger from 'koa-logger';
import helmet from 'koa-helmet';
@ -16,7 +17,8 @@ const app = new Koa();
app
.use(logger())
.use(bodyParser())
.use(helmet());
.use(helmet())
.use(cors());
routing(app);