rasengan
Version:
The modern React Framework
20 lines (19 loc) • 980 B
TypeScript
import { RouterComponent } from '../interfaces.js';
import { RouteObject, LayoutComponent, Metadata } from '../types.js';
/**
* This function receives a router component and get a formated router first
* and then return a router.
*/
export declare const getRouter: (routerInstance: RouterComponent) => () => import("react/jsx-runtime.js").JSX.Element;
/**
* This function receives a router component and return a formated router for static routing
* @param router Represents the router component
* @returns
*/
export declare const generateRoutes: (router: RouterComponent, isRoot?: boolean, parentLayout?: LayoutComponent | undefined) => RouteObject[];
/**
* This function receives a router component and return a mapping from path to metadata
* @param router Represents the router component
* @returns
*/
export declare const generateMetadataMapping: (router: RouterComponent, isRoot?: boolean, parentLayout?: LayoutComponent | undefined) => Record<string, Metadata>;