-
-
Notifications
You must be signed in to change notification settings - Fork 483
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
feat: add possibility to disable default redirect for prefix_and_default strategy #1437
base: v7
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This would also need documentation to be updated with new option and some tests.
…AndDefaultRedirect) enabled
rchl Thanks for the quick review. Unfortunately, I will only be able to continue working on the task today. I decided to abandon the route array and changed the implementation following your advice. Updated the information in the first post |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have not looked properly at the changes yet because many tests are failing.
275aa9f
to
3297711
Compare
Corrected the code that was causing the tests to crash |
I need this feature ! please, thanks... @Renhor any update bro? |
This feature would be highly appreciated. Get in touch with me, if there is anything I can do. |
Regarding to issue #1401
Added property to config:
It works only for strategy prefix_and_default.
It disables redirect for routes are prefixed with default language, or we can choose custom path pattern for disabling redirect behaviour:
UPD:
Added property to config:
By setting the value prefixAndDefaultRule = 'prefix' we are no longer redirected from prefixed routes and if there is no prefix then the other routers will also have no prefix.
For now, I decided not to implement an array with a list of routes for which the default behavior is disabled