0.2.0 • Published 9 years ago

koa-xframe v0.2.0

Weekly downloads
10
License
MIT
Repository
github
Last release
9 years ago

Koa XFrame

NPM version build status Test coverage David deps npm download

X-Frame-Options HTTP response header utility for Koa.

Installation

$ npm install --save koa-xframe

Usage & API

import Koa from 'koa';
import xFrame from 'koa-xframe';

const app = new Koa();

// default settings -> set X-Frame-Options to 'DENY'
app.use(xFrame());

// custom settings
// -> set X-Frame-Options to 'DENY'
app.use(xFrame('DENY'));
// -> set X-Frame-Options to 'SAMEORIGIN'
app.use(xFrame('SAMEORIGIN'));

Credits

Inspired by Koala headers.js middleware.

License

MIT

0.2.0

9 years ago

0.1.4

9 years ago

0.1.3

9 years ago

0.1.2

9 years ago

0.1.1

9 years ago

0.1.0

9 years ago