@abdulghani/routerhelper
v1.0.1
Published
a lightweight react component to setup routing quickly
Downloads
7
Maintainers
Readme
Router helper component
to setup router with config quickly
Usage
// other imports
import Router from "@abdulghani/routerhelper";
import myRoutes from "somewhere";
// usage
const RouteApp = () => {
return (
<Router routes={myRoutes} fallback={<>Please Wait</>}>
)
}
// fallback are optional
routes prop
are array of these object
- path
- exact
- component (able to use react lazy for lazy loading)