28 lines
802 B
TypeScript
28 lines
802 B
TypeScript
// AUTO-GENERATED by contracts/typegen/generator.ts, do not edit.
|
|
// Run `bun run typegen <project>` to update this file.
|
|
|
|
import type { Minify } from "./minify.ts";
|
|
|
|
export interface ViewProps {
|
|
"modules/app/views/index": {
|
|
title: string;
|
|
nav: { label: string; href: string }[];
|
|
posts: { id: string; title: string; excerpt: string }[];
|
|
};
|
|
"modules/app/views/layout": {
|
|
title: string;
|
|
nav: { label: string; href: string }[];
|
|
currentPath?: string;
|
|
};
|
|
"modules/app/views/post": {
|
|
title: string;
|
|
nav: { label: string; href: string }[];
|
|
post: { id: string; title: string; excerpt: string } | null;
|
|
};
|
|
}
|
|
|
|
/** Path of a view of the project. */
|
|
export type ViewPath = keyof ViewProps;
|
|
|
|
/** Props of a single view. */
|
|
export type ViewPropsOf<P extends ViewPath> = Minify<ViewProps[P]>;
|