Skip to content
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

Trailing slash missing in URLs #7

Open
ABrisset opened this issue Nov 17, 2015 · 1 comment
Open

Trailing slash missing in URLs #7

ABrisset opened this issue Nov 17, 2015 · 1 comment

Comments

@ABrisset
Copy link

When sitemap is build, each URL misses the trailing slash, i.e /. That leads to 301 redirects to URL with trailing slash, which is not optimal for SEO.
Could you automatically add this trailing slash ? Thanks !

@shaunakv1
Copy link

Running into same problem here due to removal of trailing slashes. Seems like the trailing slashes are being specifically removed as can be seen in this line:

https://github.com/statonjr/middleman-sitemap/blob/master/templates/sitemap.xml.erb#L5

I am just going to download the extension and remove the code .gsub(/\/$/,'') from it, however it will be nice to have this as a configuration option in the extension. I will submit a pull request if I get around to implementing it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants