$ npm install --save bragg-cors
const bragg = require('bragg');
const cors = require('bragg-cors');
const app = bragg();
app.use(ctx => {
ctx.body = {
unicorn: '🦄'
};
});
app.use(cors('https://www.foo.io'));
exports.handler = app.listen();
Type: string
A URI that may access the resource.
MIT © Sam Verschueren