procedural-to-declarative
    Preparing search index...

    Interface Track<TNumber>

    The data structure that tracks the procedural and declarative tasks of a system. Used to compile procedural state transitions into declarative time-to-state functions.

    interface Track<TNumber extends number = number> {
        isCompilingOrEvaluating: boolean;
        isMaterialized: boolean;
        refs: Ref<any>[];
        tasks: Set<Task<TNumber>>;
        time: TNumber;
    }

    Type Parameters

    • TNumber extends number = number
    Index

    Properties

    isCompilingOrEvaluating: boolean

    Whether the track is currently compiling or evaluating. Used to prevent compile() and useCompiled() being called from procedural / declarative functions.

    isMaterialized: boolean

    Whether the track is currently running a declarative function. Used to prevent procedural / declarative functions being called from a declarative function.

    refs: Ref<any>[]

    The refs used in the procedural and declarative functions. May be added to by useRef() calls.

    tasks: Set<Task<TNumber>>

    The active or registered tasks within this track.

    time: TNumber

    The current time of the track used when compiling.