@webroute/routerFunctions
createLinearRouter
createLinearRouter<
T
>(initialRoutes
):RequestRouter
<T
>
Creates a linear web router.
Route matching is determined by:
- Method specificity: more specific methods are prioritised, wildcards deprioritised.
- Registration order: within a method, routes registered earlier are prioritised.
Type Parameters
Type Parameter |
---|
T |
Parameters
Parameter | Type |
---|---|
initialRoutes | RouteInput <T >[] |
Returns
RequestRouter
<T
>