Next.js has made me soft
I know this is a total dumb question, but I'm struggling with the basics. I am trying to follow a similar pattern as the "React Example: Kitchen Sink Multi File", but am failing. I haven't even gotten to the "hard" part of wanting a component to handle both /page and /page/:id, I'm just trying to implement the start / and /page. Sorry for the dumb question.
Here's the code: https://stackblitz.com/edit/vitejs-vite-ky3ywz?file=src/App.jsx.
tanstack/react-router beta - StackBlitz
wasn't supposed to work :)
1 Reply
probable-pinkOP•3y ago
This approach does not work either: https://stackblitz.com/edit/vitejs-vite-jfv2wk?file=src/router.jsx, which seems like the cleanest approach for a big project. However, putting all routes in a single file does work (though not in beta-34): https://stackblitz.com/edit/vitejs-vite-rpecul?file=src/App.jsx. I'm so confused.