UNPKG

@nolebase/vitepress-plugin-page-properties

Version:

A VitePress plugin that renders frontmatter as page properties, and makes them editable.

16 lines (15 loc) 594 B
import type { PageData } from 'vitepress'; import type { ComputedRef, Ref } from 'vue'; import VirtualPagePropertiesData from 'virtual:nolebase-page-properties'; type AggregatedPageProperties = Array<{ key: PropertyKey | 'unknown'; pageProperty: Property<any>; value: any; omitEmpty: boolean; }>; export declare function usePageProperties(pageData: Ref<PageData>, userConfiguredPageProperties: ComputedRef<Property<any>[]>): { config: ComputedRef<AggregatedPageProperties>; data: ComputedRef<any>; update(data: typeof VirtualPagePropertiesData): void; }; export {};