https-rewrite
v1.0.1
Published
Rewrites http requests to https
Downloads
1
Maintainers
Readme
https-rewrite
Rewrite URLs to https.
Install
npm install --save https-rewrite
Usage
Currently only express@^4.0.0
is supported as the engine to perform rewrites in.
express
const redirectToHttps = require('https-rewrite/express');
// ... set up express
// Should be one of the topmost (if not the) middlewares.
app.use(redirectToHttps({
// Change the status code used to redirect. Defaults to 307.
status: 301
}))
License
MIT © jutaz