mobx-bonsai
    Preparing search index...

    Type Alias VolatileProp<TTarget, TValue>

    VolatileProp: readonly [
        getter: (target: TTarget) => TValue,
        setter: (target: TTarget, value: TValue) => void,
        reset: (target: TTarget) => void,
    ]

    Represents a volatile property on an object using a tuple of functions.

    This type defines a readonly tuple with three functions:

    • A getter that retrieves the current value of the volatile property from the target object.
    • A setter that updates the volatile property with a new value on the target object.
    • A reset function that restores the volatile property on the target object to its default state.

    Type Parameters

    • TTarget extends object

      The type of the object that holds the volatile property.

    • TValue

      The type of the volatile property's value.