Skip to main content
cngx-src documentation

withTocSpy

Functionui/tocv0.1.0

projects/ui/toc/config/features.ts

Description#

Move the app-wide CngxScrollSpy defaults - the rootMargin and threshold the rail forwards to its internal spy. Per-instance [rootMargin] / [threshold] bindings still win; this only sets the cascade default (e.g. a fixed-header offset every toc should share).

provideTocConfig(withTocSpy({ rootMargin: '-80px 0px 0px 0px' }));

Signature#

withTocSpy(payload: NonNullable)

Parameters#

@parampayloadNonNullable

Returns#

CngxTocConfigFeature