2023-07-01 07:03:01 +00:00
|
|
|
import { Node, Parent } from 'hast'
|
|
|
|
import { Data, VFile } from 'vfile'
|
2023-05-30 15:02:20 +00:00
|
|
|
|
|
|
|
export type QuartzPluginData = Data
|
|
|
|
export type ProcessedContent = [Node<QuartzPluginData>, VFile]
|
2023-07-01 07:03:01 +00:00
|
|
|
|
|
|
|
export function defaultProcessedContent(vfileData: Partial<QuartzPluginData>): ProcessedContent {
|
|
|
|
const root: Parent = { type: 'root', children: [] }
|
|
|
|
const vfile = new VFile("")
|
|
|
|
vfile.data = vfileData
|
|
|
|
return [root, vfile]
|
|
|
|
}
|