signalSnapshot (Function)
Signature: signalSnapshot(work: () -> t0) -> { dependencies: List<string>, revision: int, value: t0 }
Description: Runs a computation once and returns its value, compiler-derived signal dependencies and revision 1.
Parameters
- work (() -> t0): A zero-argument computation under its required handlers
Returns: { dependencies: List
Example
let cached = signalSnapshot(counterLabel)
cached = signalSnapshot counterLabel