@tempots/ui
Router() function
Creates a router that maps routes to corresponding renderable components.
Signature:
Router: extends { [K in keyof T]: (info: K extends string ? Signal<RouteInfo<MakeParams<ExtractParams>, K>> : never) => TNode; }>(routes: T) => Renderable
Parameters
Parameter |
Type |
Description |
---|---|---|
routes |
T |
An object containing route handlers. |
Returns: Renderable
- The router renderable.