Skip to content

prismjs/internals

ClassDescription
PrismTokenRepresents a parsed token produced by Prism’s tokenizer.
InterfaceDescription
EnvironmentEnvironment object passed to Prism hooks and used during highlighting.
GrammarA Prism grammar definition, combining common token names with arbitrary additional tokens.
GrammarRestCommon grammar token names with optional rest grammar reference.
GrammarValueA grammar value: a single regex, a token object, or an array of either.
HighlightCallbackCallback invoked after an element is highlighted.
HookCallbackCallback function invoked by a Prism hook.
HookTypesMap of hook names to their registered callback arrays.
LanguageMapMap of language identifiers to their grammar definitions.
LanguageMapProtocolProtocol for extending and modifying Prism language definitions.
LanguagesThe Prism languages registry, combining the language map with protocol methods.
PrismHooksPrism hook system for extending highlighting behavior.
PrismModuleThe Prism.js library module type, representing the window.Prism object.
PrismTokenObjectDescribes a token pattern for Prism grammar definitions.
PrismTokenStreamA token stream: a string, a single token, or an array of strings and tokens.
PrismUtilPrism utility functions.