Module '@koa/cors' as import syntax (#4060)

This commit is contained in:
Acid Chicken (硫酸鶏) 2019-02-01 19:46:18 +09:00 committed by Aya Morisawa
parent c7afe7a3de
commit ac6ce5c7d9
2 changed files with 2 additions and 1 deletions

View file

@ -50,6 +50,7 @@
"@types/koa": "2.0.48",
"@types/koa-bodyparser": "5.0.2",
"@types/koa-compress": "2.0.8",
"@types/koa-cors": "0.0.0",
"@types/koa-favicon": "2.0.19",
"@types/koa-logger": "3.1.1",
"@types/koa-mount": "3.0.1",

View file

@ -6,7 +6,7 @@ import * as Koa from 'koa';
import * as Router from 'koa-router';
import * as multer from 'koa-multer';
import * as bodyParser from 'koa-bodyparser';
const cors = require('@koa/cors');
import * as cors from '@koa/cors';
import endpoints from './endpoints';
import handler from './api-handler';