Interface Spring<T>

Readable interface for subscribing.

interface Spring<T> {
    damping: number;
    precision: number;
    set: (new_value: T, opts?: SpringUpdateOpts) => Promise<void>;
    stiffness: number;
    update: (fn: Updater<T>, opts?: SpringUpdateOpts) => Promise<void>;
    subscribe(
        this: void,
        run: Subscriber<T>,
        invalidate?: Invalidator<T>,
    ): Unsubscriber;
}

Type Parameters

  • T
Hierarchy

Methods

Properties

damping: number
precision: number
set: (new_value: T, opts?: SpringUpdateOpts) => Promise<void>
stiffness: number
update: (fn: Updater<T>, opts?: SpringUpdateOpts) => Promise<void>