-
Notifications
You must be signed in to change notification settings - Fork 141
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
Map url with trailing slash to edit #63
Comments
hmm... I'm pretty much relying on path-to-regexp, but I'm sure it could be customized. So basically the slash triggers a route with a param after the slash. Is this 100% the idiom here, or just specific to angular ui-router? Doesn't React Router handle it like RFR handles it? That's why they have the I personally don't like that slash making such a big difference. I'd prefer the But it's really whatever is truly standard here that we should be doing. |
Haven't used React Router yet. Redux First Router is my router of choice for React, state-based routing is better than physically routing components to urls, and I didn't struggle making code-splitting work via RFR's thunk. I think it's not specific to angular ui-router, tried the older version of React Router now, /company/ and /company/fb maps to same route: /company/:companyCode. https://fiddle.jshell.net/jcdasrn2/ Tried the new version (React Router 4), the behavior is now different though, both /company/ and /company maps as same route. Haven't checked yet if it can be configured to make it behave like its older version. |
glad to hear that RFR is your router of choice lol! I really don't think I'll be able to do much about this one brother, especially if RR4 is also doing it by default. Just FYI. But thanks for researching this, it's basically a PR you provided. Makes the decision here. |
I'm going to close this for now. Feel free to re-open if you need. |
Currently, with this routesMap:
The url /company/ maps to COMPANY_LIST instead of to COMPANY_FORM.
Could we make /company/ maps to COMPANY_FORM instead?
Having used angular ui-router, it could facilitate this kind of url idiom for list, new, and edit:
Or we could keep /company and /company/ maps to same route, but could we have a way to configure that /company/ and /company/:companyCode maps to same route?
The text was updated successfully, but these errors were encountered: