[BUG] `refine-react-router-v6` does not apply `options.route` correctly
See original GitHub issueDescribe the bug
Given a configuration with two resources:
resources={[
{
name: 'users',
list: UserList
},
{
name: 'users',
list: LegacyUserList,
options: {
dataProviderName: 'users-legacy'
route: 'users-legacy',
label: 'Users (Legacy)'
},
}]
While both routes are available in the sense that they do not return 404 errors, the routing differs between versions.
With refine-react-router
:
/users
rendersUserList
/users-legacy
rendersLegacyUserList
With refine-react-router-v6
:
/users
rendersUserList
/users-legacy
rendersUserList
Also, refine-react-router-v6
doesn’t use the correct data provider, the rendering is exactly the same for /users
and /users-legacy
.
Expected behavior
v6
should render the same as v5
.
Issue Analytics
- State:
- Created 2 years ago
- Comments:6 (6 by maintainers)
Top Results From Across the Web
Issues - GitHub
[Bug]: Relative navigation issue while navigating from "index" route: ". ... The workaround is to use resolvePath that has no relation to <Route>...
Read more >CSCts39535 - bgp outbound route-map, [un ... - Cisco Bug
Thus, the route map may not be applied correctly, resulting in erroneous filtering or advertising of unintended routes.
Read more >76511 – /sbin/ip does not set routing table properly for "equal ...
Description of Problem: We try to test (and if successful use) "equal cost multipath" routing using RH80 and iproute. But the /sbin/ip binary...
Read more >Bug #1564460 “Router set --route option does not work”
The router set --route option does not work. $ openstack router set --route destination=10.10.10.0/24,gateway=10.10.10.1 foo
Read more >How can I redirect in React Router v6? - Stack Overflow
I think you should use the no match route approach. ... these components to avoid unnecessary redirects on clicking back and forward option....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Found it, the order of resources is important. See https://codesandbox.io/s/refine-base-example-forked-l5uxt7.
Hey @rassie , Thank you! We’ve released
@pankod/refine-react-router-v6@3.7.1
. Could you approve this fix?