1.0.1 • Published 7 years ago
https-rewrite v1.0.1
https-rewrite
Rewrite URLs to https.
Install
npm install --save https-rewriteUsage
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