Reputation: 590
How we can create a react sidebar admin themes with react router?
Upvotes: 3
Views: 12461
Reputation: 166
You can see a sidebar examples .
Upvotes: 2
Reputation: 312
You can create a wrapper component that is the sidebar itself. Then, setup your desired routes to be wrapped with a sidebar.
This approach has the benefit of keeping all the logic in your router without requiring modifications to any of your current components. It will also work great for server side rendered apps if you decide to move in that direction.
Upvotes: 0