Builder (paths & values)

[data/tree/Builder (paths & values)]


Constructs a tree data structure based on the path-value pairs received via paths and values. Bounces when the length of values and path don't match.


Keywords: zip, construct

Input ports

  • paths: (string or number)[][]

    Receives paths that form the structure of the constructed tree.

  • values: any[]

    Receives the values that will be the leaf nodes of the constructed tree.

Output ports

  • tree: any

  • bounced: {"paths": (string or number)[][], "values": any[]}

Last updated