Skip to main content
cngx-src documentation

CngxLatencyProbe

Interface

projects/core/utils/latency-probe.ts

Import#

import { CngxLatencyProbe } from '@cngx/core/utils'

Description#

Measured busy-envelope duration for a boolean-busy source.

lastDuration is the wall-clock length of the most recently completed busy window, or undefined before the first window closes. isBusy mirrors the source. A consumer compares lastDuration() against a cutoff to pick, e.g., a spinner (fast last operation) vs a skeleton (slow last operation) before the next window even opens.

Index#

Instance Properties#

isBusy#Signal
Readonly

true while the source reports busy.

lastDuration#Signal
Readonly

Duration in ms of the last completed busy window, undefined until one closes.