Live data from Hacker News

Avoiding the Trailing Slash Tax on GitHub Pages and Astro

justoffbyone.com

1–3 of 3 posts

Re: Avoiding the Trailing Slash Tax on GitHub Pages and Astro

#2
weird post. I mean, you set the permalink scheme in your config how you want. Of course it treats files and directories differently. Your scheme is trailing-slash. So traffic to no-trailing-slash is going to 301. You're lucky it 301s instead of 404.

Re: Avoiding the Trailing Slash Tax on GitHub Pages and Astro

#3

weird post. I mean, you set the permalink scheme in your config how you want. Of course it treats files and directories differently. Your scheme is trailing-slash. So traffic to no-trailing-slash is going to 301. You're lucky it 301s instead of 404.

This site is hosted on Github Pages as a statically built site; it's not served by Astro. I don't think I can control what they do with trailing slashes or the lack of it. This is also clarified on the Astro config.