Interface Mapping<Source, Target>

Keeps an array of result objects synchronized with an array of source objects. See with arrays.

Mapping provides a map function that updates its results. The map function can be called multiple times and the results will get created, removed and updated accordingly. A Mapping can be used to keep an array of components (objects with a render method) synchronized with an array of data. Instances of Mapping can be created using createMapping.

Type Parameters

  • Source

    The type of source elements. Usually the data type.

  • Target

    The type of target elements. Usually the component type.


  • Mapping




results: Target[]

The array of results. These results will be synchronized with the latest array of sources that were provided using map.


  • Maps a new array of sources and updates results.


    • newSources: Source[]

      The new array of sources.

    Returns void

Generated using TypeDoc