@tanstack/router-generator
Version:
Modern and scalable routing for React applications
34 lines (33 loc) • 1.05 kB
text/typescript
import { Config } from './config.cjs';
type TemplateTag = 'tsrImports' | 'tsrPath' | 'tsrExportStart' | 'tsrExportEnd';
export declare function fillTemplate(config: Config, template: string, values: Record<TemplateTag, string>): Promise<string>;
export type TargetTemplate = {
fullPkg: string;
subPkg: string;
rootRoute: {
template: () => string;
imports: {
tsrImports: () => string;
tsrExportStart: () => string;
tsrExportEnd: () => string;
};
};
route: {
template: () => string;
imports: {
tsrImports: () => string;
tsrExportStart: (routePath: string) => string;
tsrExportEnd: () => string;
};
};
lazyRoute: {
template: () => string;
imports: {
tsrImports: () => string;
tsrExportStart: (routePath: string) => string;
tsrExportEnd: () => string;
};
};
};
export declare function getTargetTemplate(config: Config): TargetTemplate;
export {};