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

Don't remove extension in links #180

Merged
merged 2 commits into from
Dec 13, 2023
Merged

Don't remove extension in links #180

merged 2 commits into from
Dec 13, 2023

Conversation

camsteffen
Copy link
Contributor

Description

Don't remove the .md extension from markdown links since this prevents docusaurus from converting the link to an absolute URL, causing #157.

See also docusaurus docs on Markdown links.

I also added trailingSlash: true to the docusaurus config so that internal links have trailing slashes, which aligns with the Github Pages behavior of redirecting with a trailing slash.

Related Issues

Fixes #157

Check List

This was breaking relative links when a trailing slash is included in
the current URL. If the file extension is included, then Docusaurus can
convert the links to have absolute URLs, so the trailing slash in the
current URL doesn't matter.
Copy link
Member

@Eomm Eomm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👏🏼 🙏🏼

@Eomm Eomm merged commit 7a4eeec into fastify:main Dec 13, 2023
4 checks passed
@camsteffen camsteffen deleted the broken-links branch December 13, 2023 14:25
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.

Inconsistent trailing slash, broken links
2 participants