hapi-trailing-slash

3.1.1 • Public • Published

hapi-trailing-slash # Build Status

Handles common trailing slash issues for incoming URLs

###register like so:###

var module = require("hapi-trailing-slash");
.
.
.
server.register({
  register: module,
  options: {
    method: 'remove',
    verbose: true
  }
});

###options are:###

  • 'append' -- detects incoming requests that have no trailing slash, adds one, and redirects to the new url
  • 'remove' -- detects incoming requests with a trailing slash, removes it, and redirects to the new url

Readme

Keywords

none

Package Sidebar

Install

npm i hapi-trailing-slash

Weekly Downloads

31

Version

3.1.1

License

MIT

Unpacked Size

15.5 kB

Total Files

9

Last publish

Collaborators

  • jga
  • dawnerd
  • ecwillis
  • orthagonal1
  • alaguna
  • aleperez92