Skip to content

PrismModule.highlightElement method

PrismModule › highlightElement

Unofficial

Highlights a single element.

Signature:

highlightElement(element: Element, async?: boolean | undefined, callback?: HighlightCallback | undefined): void

Parameters:

ParameterTypeDescription
elementElementThe element to highlight.
async?boolean | undefinedWhether to use web workers.
callback?HighlightCallback | undefinedCallback invoked after the element is highlighted.

Returns: void