Javascript – Migrating from react-router-dom v5 to v6 structure
I have a similar structure as the one below in my project, currently using react-router-dom v5. Let's call this <Routes /> component: <Switch> <Redirect from="/" to="/some/path" /> <Redirect from="/main" to="/some/path" /> <Route path="/main" component={SomePage} /> </Switch> And inside <SomePage />,…