Skip to content
@ng-doc/app / Class

NgDocCodeHighlighterDirective

Renders the given Angular HTML code, highlighted by NgDocHighlighterService, into its host element.

Decorators
@Directive
Selectors
[ngDocHighlighter]
DeclarationTypeScript
@Directive({ … })
export class NgDocCodeHighlighterDirective { … }

Members

Properties

5
code: InputSignal<string>
readonly input()required

The code to highlight.

element: any
protectedreadonly
—
highlightedCode: Signal<SafeHtml>
protectedreadonly
—
protectedreadonly
—
sanitizer: DomSanitizer
protectedreadonly
—
Symbol
Kind
Class
Decorators
@Directive
Selectors
[ngDocHighlighter]
Scope
@ng-doc/app
Edit this page