Reactjs – Redirect All Matches of Path without Root Folder in React Router
I'm using react-router-dom version 6.3.0 and I'm trying to make my router handle an updated URL structure. As an example, my old routes look like this: <Route path='animals/dog' element={<Dog />} /> <Route path='animals/cat' element={<Cat />} /> <Route path='animals/bird/songs' element={<BirdSongs />}…