Skip to content

withoutTokenizer

const withoutTokenizer: (text, grammar) => TokenStream

Defined in: prism/core.d.ts:123

Same as tokenizeText, but doesn’t call the potential custom tokenizer of the grammar. This is useful inside a custom tokenizer where tokenizeText can cause infinite recursion.

string

A string with the code to be highlighted.

Grammar

An object containing the tokens to use.

TokenStream

tokenize for more info on custom tokenizers.