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

404 for trailing slashes in URLs (next.js issue) #48

Closed
nuke-web3 opened this issue Jan 16, 2025 · 1 comment
Closed

404 for trailing slashes in URLs (next.js issue) #48

nuke-web3 opened this issue Jan 16, 2025 · 1 comment

Comments

@nuke-web3
Copy link
Member

Example: https://celestia.org/glossary/ is a 404 but https://celestia.org/glossary is fine
Seems a workaround might be: https://blog.theletstream.com/handling-404-trailing-slash-error-in-nextjs-f8844545afe3?gi=3c1f6bf1639e but a bit more research for a proper fix might be warranted.

https://www.perplexity.ai/search/i-have-a-react-website-that-yi-w5kwlKmaQeiqJdVtz3gi3w seem to suggest https://nextjs.org/docs/pages/api-reference/config/next-config-js/trailingSlash could be all we need 🤞 this might work:

/** @type {import('next').NextConfig} */
const nextConfig = {
.......
  trailingSlash: true,
};
@alex-beckett
Copy link
Contributor

thanks, fixed with #52

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