Interface Options<T, TChangeSummary>

interface Options<T, TChangeSummary> {
    createChangeSummary?: (() => TChangeSummary);
    isEqual?: ((a, b) => boolean);
    willHandleChange?: (<U, UChange>(context, changeSummary) => boolean);
}

Type Parameters

  • T
  • TChangeSummary

Properties

createChangeSummary?: (() => TChangeSummary)

Creates a change summary that can collect the changes reported by the observed dependencies to willHandleChange.

Type declaration

isEqual?: ((a, b) => boolean)

Type declaration

    • (a, b): boolean
    • Parameters

      Returns boolean

willHandleChange?: (<U, UChange>(context, changeSummary) => boolean)

Handles a change reported by an observed dependency, e.g. by adding it to the changeSummary. Returns true if the reported change should be reacted to, and false if it should be ignored.

Type declaration