
Rethinking React routing: a simpler, more predictable approach
I built a modern React router because I was tired of existing ones Routing in React has always felt… either too simple or too complicated. Some routers feel too minimal — you end up building everything yourself Others feel over-engineered — great power, but heavy mental overhead So I built my own. 👉 Introducing routexiz — a lightweight, modern router for React with a clean mental model. 🧠 The idea: routing as a tree Instead of thinking in flat routes, routexiz models your app like a tree. Each route is a node. Navigation resolves a single path from root to leaf . route ( " / " , Layout , root => { root . route ( " /dashboard " , Dashboard , dash => { dash . guard ( authGuard ) dash . middleware ( trackPageView ) }) }) This gives you: Natural nested layouts Predictable execution Clear structure as your app grows ⚡ Navigation that understands your route Instead of this: navigate ( " /users/1 " ) You write: navigate ( " /users/:id " , { params : { id : 1 } }) No string guessing. No mismat
Continue reading on Dev.to React
Opens in a new tab



