koa-cors-error
v0.0.2
Published
Allow 4xx or 5xx statuses for cross-domain requests.
Downloads
1,079
Readme
koa-cors-error
Bug fixed bug whith 4xx or 5xx not sent while cross-domain requests.
koa onerror
method have been completely replaced.
Installation
$ npm install koa-stylish
Use
var corsError = require('koa-cors-error');
app.post('/api/cors', cors, corsError, function *() {
this.throw(401);
});