Router for any browser-based JavaScript app
Install by npm:
npm install --save @do-while-for-each/browser-router
or install with yarn:
yarn add @do-while-for-each/browser-router
Using the example for React.js:
- Define routes (for a possible syntax see here)
- Create
BrowserRouter
instance - Start
BrowserRouter
- Receive and handle the routing result
and that's all you need to do to make the router work.