Node getter

[data/tree/Node getter]


Retrieves the node at the specified path of the tree. Example:

  1. {"foo": {"bar": "baz"}}@0 is received via tree

  2. ["foo", "bar"]@0 is received via path

  3. "baz"@0 is sent via node


Keywords: picker, get, lookup

Input ports

  • tree: (any[] or {string: any})

    Receives the tree the node is extracted from

  • path: (string or number)[]

    Receives the path segments in an array

Output ports

  • node: any

    Sends the node at the specified path

  • not found: (string or number)[]

    Sends the path if it was not found

Last updated