-
-
Notifications
You must be signed in to change notification settings - Fork 10.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
All routes/urls should have a trailing slash. Missing trailing slashes should be added #448
Comments
Was lookng for the best way to do this. Middleware, regex, something else? Found this interesting read: https://groups.google.com/forum/#!topic/express-js/-irYaQqRZ3M A summary of the interesting points:
Therefore the suggested solution is to do this:
And there is middleware available to do it: https://github.com/avinoamr/connect-slashes |
I would prefer to have a trailing slash on everything and just keep it consistent - what the trailing slash actually means is largely conjecture/speculation. Feels like the old days of arguing .php/.asp vs .htm |
ref issue TryGhost#448 - adds slashes to urls, templates and tests TODO Add function to add slash to urls automatically
ref issue #448 - adds slashes to urls, templates and tests TODO Add function to add slash to urls automatically
Every route in Ghost should expect a trailing slash.
The text was updated successfully, but these errors were encountered: