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

How to navigate to route with trailing slash #301

Open
micahjon opened this issue Aug 27, 2021 · 2 comments
Open

How to navigate to route with trailing slash #301

micahjon opened this issue Aug 27, 2021 · 2 comments

Comments

@micahjon
Copy link

micahjon commented Aug 27, 2021

Hi, we've been using Navigo 7 in production for a few years and it's been working great--thanks for all your hard work on this.

I'm working on migrating to version 8 but I noticed that trailing slashes are being stripped from all our URLs. Is this behavior configurable in Navigo 8? It looks like it's currently hard-coded:

to = to ? `${clean(root)}/${clean(to)}` : undefined;

Thanks!

@krasimir
Copy link
Owner

Hey,

unfortunately that's a decision that I took when started working on version 8. Without that I was facing a lot more issues. It's not configurable at the moment.

@micahjon
Copy link
Author

No worries, we'll just stick with v7 for now.

If there are performance/reliability reasons for switching to v8, let me know, and I'd be happy to help with a PR and write some tests to help make this configurable.

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