lagunovsky / redux-react-router

A Redux binding for React Router v6
MIT License
73 stars 9 forks source link

Enable chosing different Routers. #15

Open SerdarSanri opened 2 years ago

SerdarSanri commented 2 years ago

Currently main component is plain Router component. With recent changes in React-router v6.4+ some hooks can only run if you are using data routers like createBrowserRouter or BrowserRouter. Using embed Router component makes this library incompatible with new updates.

plxmargaux commented 1 year ago

What's the update on that one? Thanks a lot!

asherccohen commented 1 year ago

bump on this one

lagunovsky commented 1 year ago

I don't think it's possible. Because of new data APIs like loaders, actions, fetchers.

PR is welcome.

tjad-oivan commented 1 year ago

What are the full list of requirements for achieving this ?

dannutiee commented 10 months ago

Hi, is there any update on this one? 🙏

I am trying to use new router v6 hooks (e.g useBlocker) but they can be only used within Router that supports new data API (e.g RouterProvider) 😭

I tried to get around it by nesting <RouterProvider /> inside <ReduxRouter / > 👀 as someone tried here #20 but I ended with the same error 💁‍♀️ "You cannot render a <Router> inside another <Router>" (#20).

Looks that we cannot:

drosenzweig commented 9 months ago

I'm in the exact same position as @dannutiee. Migrating a fairly large application from router v5 to v6, and got everything working up until trying to use the new data API.

efraimrodrigues commented 9 months ago

Same as @dannutiee .

SerdarSanri commented 8 months ago

added a PR two years ago but still didn't get merged. with react-router v2 it us unfortunately not possible to use redux-react-router so we decided to not use it anymore and dropped the dependency.