Skip to content

Function: injectViewport()

@roomful/angular


@roomful/angular / injectViewport

injectViewport<TPresence>(options?): InjectViewportResult

Defined in: angular/src/index.ts:864

Subscribes to viewport snapshots and returns mounting and control helpers.

Must be called in an injection context. Angular has no React-style callback ref, so mount the engine on an element from afterNextRender or ngAfterViewInit by calling InjectViewportResult.mount.

TPresence extends PresenceData = PresenceData

The room presence shape.

ViewportOptions

Optional viewport tracking configuration.

InjectViewportResult

The remote viewport states signal plus mounting and follow controls.