Skip to content

Interface: ComputedOptions<T>

API / @xmachines/play-signals / ComputedOptions

Defined in: packages/play-signals/src/types.ts:85

The options of a Signal.Computed

Param

equals

The optional equality function of your own, for the memoization

Example

import { Signal } from "@xmachines/play-signals";
import type { ComputedOptions } from "@xmachines/play-signals";
const options: ComputedOptions<string> = {
equals: (a, b) => a.toLowerCase() === b.toLowerCase(),
};

Type Parameters

Type Parameter
T

Properties

PropertyTypeDescriptionDefined in
equals?(a, b) => booleanThe equality function of your own, for the memoizationpackages/play-signals/src/types.ts:89