UNPKG

@rshirohara/rekurke-parse

Version:
15 lines (12 loc) 459 B
import type { Root as KkastRoot } from "@rshirohara/kkast"; import type { Plugin, Processor } from "unified"; import { fromKakuyomuNovel } from "./lib/index.js"; export const rekurkeParse: Plugin<[], string, KkastRoot> = function ( this: Processor, ) { const parser = (doc: string) => { return fromKakuyomuNovel(doc); }; // biome-ignore lint/style/useNamingConvention: interface defined in external module Object.assign(this, { Parser: parser }); };