Skip to content

Allow enforcement of trailing slashes on urls and links #203

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

Draft
wants to merge 9 commits into
base: master
Choose a base branch
from

Conversation

jesseleite
Copy link
Member

@jesseleite jesseleite commented Jun 27, 2025

This PR adds config to enforce trailing slashes on urls and links during SSG generation. This is useful for things like SEO sitemap, RSS feeds, etc. on server hosts that bias towards trailing slashes (ie. Netlify expects trailing slashes for SEO).

Todo

  • Add opt-in config
  • Wire up config to enforce trailing slashes on ssg:generate only
    • We don't want this always running in the service provider!
  • Flesh out test coverage
  • Update composer constraint (once Statamic v6 is tagged)

References #65
References statamic/cms#11840

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

Successfully merging this pull request may close these issues.

1 participant