@vivliostyle/vfm
Version:
Custom Markdown syntax specialized in book authoring.
22 lines (21 loc) • 620 B
TypeScript
import { ElementContent as HastElementContent } from 'hast';
import { Handler } from 'mdast-util-to-hast';
import refractor from 'refractor';
import { Node } from 'unist';
interface HProperties {
id?: string;
class?: string[];
title?: string;
[key: string]: unknown;
}
declare module 'mdast' {
interface Code {
data?: {
hProperties?: HProperties;
hChildren?: HastElementContent[] | ReturnType<typeof refractor.highlight>;
};
}
}
export declare function mdast(): (tree: Node) => void;
export declare function handler(h: any, node: any): Handler;
export {};