Interface MarkdownCodeContextInternal

Hierarchy

Properties

baseUrl?: string

A prefix URL for any relative link.

breaks?: boolean

Enable GFM line breaks. This option requires the gfm option to be true.

getLanguage: GetCodeLanguage

A function that can be used to get the language for a block of code or allow different aliases.

Returns

The language to use

gfm?: boolean

Enable GitHub flavored markdown.

headerIds?: boolean

Include an id attribute when emitting headings.

headerPrefix?: string

Set the prefix for header tag ids.

highlightCode?: DangerouslyHighlightCode

This function is mostly used if you'd like to be able to have the code highlighted via dangerouslySetInnerHTML so that the code can be highlighted in node environments.

Returns

the html to dangerously set within a <code> tag

highlightElement?: HighlightElement

A function that should highlight all the code within an HTMLElement. This should normally just be something like Prism.highlightElement or HighlightJS.highlightElement.

langPrefix?: string

Set the prefix for code block classes.

mangle?: boolean

Mangle autolinks (email@domain.com).

pedantic?: boolean

Conform to obscure parts of markdown.pl as much as possible. Don't fix any of the original markdown bugs or poor behavior.

renderer?: Renderer<never>

Type: object Default: new Renderer()

An object containing functions to render tokens to HTML.

silent?: boolean

Shows an HTML error message when rendering fails.

smartLists?: boolean

Use smarter list behavior than the original markdown. May eventually be default with the old behavior moved into pedantic.

smartypants?: boolean

Use "smart" typograhic punctuation for things like quotes and dashes.

tokenizer?: Tokenizer<never>

The tokenizer defines how to turn markdown text into tokens.

walkTokens?: ((token) => void)

Type declaration

    • (token): void
    • The walkTokens function gets called with every token. Child tokens are called before moving on to sibling tokens. Each token is passed by reference so updates are persisted when passed to the parser. The return value of the function is ignored.

      Parameters

      Returns void

xhtml?: boolean

Generate closing slash for self-closing tags (
instead of
)

Generated using TypeDoc