Installation
npm install --save @types/remark-prism
Summary
This package contains type definitions for remark-prism (https://github.com/sergioramos/remark-prism#readme).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/remark-prism.
index.d.ts
import { Root } from "mdast";
import { Plugin } from "unified";
type SupportedPlugins =
| "autolinker"
| "command-line"
| "data-uri-highlight"
| "diff-highlight"
| "inline-color"
| "keep-markup"
| "line-numbers"
| "show-invisibles"
| "treeview";
declare namespace remarkPrism {
interface Options {
transformInlineCode?: boolean;
plugins?: SupportedPlugins[];
}
/**
* Plugin to use prism with remark.
* https://github.com/unifiedjs/unified/blob/main/index.d.ts#L488-L489
*/
type Prism = Plugin<[Options?] | undefined[], Root, Root>;
}
declare const remarkPrism: remarkPrism.Prism;
export = remarkPrism;
Additional Details
- Last updated: Tue, 07 Nov 2023 15:11:36 GMT
- Dependencies: @types/mdast, remark, unified
Credits
These definitions were written by Hojun Bun, and Stephen Weiss.