projects/common/data/async-state/operators.ts
import { AsyncStateSink } from '@cngx/common/data'
Minimal write interface for async state operators.
Any ManualAsyncState<T> satisfies this - operators only need the write side.
ManualAsyncState<T>
function
Optional read side: when present, tapAsyncState picks refreshing over loading for a re-subscribe after data has already landed. Any ManualAsyncState<T> provides it.
tapAsyncState
refreshing
loading
void
set(status: "idle" | "loading" | "refreshing" | "pending")
"idle" | "loading" | "refreshing" | "pending"
setError(error: unknown)
unknown
setProgress(value: number | undefined)
number | undefined
setSuccess(data: T)
T