@kayahr/signal
    Preparing search index...

    Interface ObservableToSignalOptions<T, Init>

    Options specific to converting an observable to a signal.

    interface ObservableToSignalOptions<T, Init = undefined> {
        equals?: false | ((previous: T | Init, next: T | Init) => boolean);
        initialValue?: Init;
        requireSync?: boolean;
    }

    Type Parameters

    • T
    • Init = undefined

    Hierarchy (View Summary)

    Index
    equals?: false | ((previous: T | Init, next: T | Init) => boolean)

    Compares the previous and next signal value.

    Returning true suppresses the update and keeps dependent computations clean. Set this to false to force an update for every source value.

    The previous signal value.

    The next signal value.

    True when both values should be treated as equal.

    initialValue?: Init

    The initial signal value used before the source produces its first value.

    requireSync?: boolean

    Forces the observable to emit a value synchronously during subscription.