react-router-dom upgrade to v6 #4111
Replies: 2 comments 2 replies
-
Hey @alexanderbartels have you seen this repo? Might help solve your problem. |
Beta Was this translation helpful? Give feedback.
-
For anyone experiencing this bug with npm workspaces: I had a similar issue using payload in a monorepo with a vite + react frontend. Installing a new react-router-dom@6 package in the frontend made payload receive this one as well. This is an issue with npm workspaces. Dependencies of different versions of a package only get isolated per workspace when the package and version appear in the package.json. react-router-dom doesn't appear in the CMS workspace, as it is a dependency of payload. I was able to fix this by adding |
Beta Was this translation helpful? Give feedback.
-
Hey, i'm trying to setup payload and remix in a single project/server setup. After installing remix, the /admin route can't be loaded anymore. Browser console shows a webpack error:
After some research i found out, that withRouter seems to be deprecated:
Along with the upgrade to v5.1, you should replace any usage of withRouter with hooks.
- https://reactrouter.com/en/main/upgrading/v5#upgrade-to-react-router-v51Do you have any plans to upgrade react router dom to the latest 6.x version?
I wanted to avoid the monorepo setup from the example as i'm working on a simple prototype to try out payloadcms and its capabilities.
Beta Was this translation helpful? Give feedback.
All reactions