Skip to content
@ng-doc/app / Class

NgDocContentController

Owns one body or header content source for one component instance. Provide it in the component's providers; it holds a pending task from each load until the processors accept the loaded HTML.

Decorators
@Injectable
DeclarationTypeScript
@Injectable()
export class NgDocContentController { … }

Members

Constructor

1
()
—

Properties

4
error: WritableSignal<Error | undefined>
readonly

The load or processing error of the current source.

html: WritableSignal<string>
readonly

The loaded HTML.

settled: WritableSignal<boolean>
readonly

Whether the latest load of the current source has been rendered: its version was processed, or the load or its processing failed. False while a load or its processing is pending.

version: WritableSignal<number>
readonly

Increments whenever the HTML must be processed again.

Methods

5
(…): void

Loads the source and reloads it whenever the source reports a change. Connecting the connected source again does nothing.

(): void

Cancels the current load and releases its pending task. Called on destroy.

(): void

Drops the current source and clears the HTML.

(…): void

Accepts a processing pass. Only the pass of the current version counts.

(…): void

Reports a failed processing pass. Only a failure of the current version counts.

Symbol
Kind
Class
Decorators
@Injectable
Scope
@ng-doc/app
Edit this page