Function getJsonValuesByName

  • Finds all elements of type T with a given name in a JsonMap. Not suitable for use with object graphs containing circular references. The specification of an appropriate type T that will satisfy all matching element values is the responsibility of the caller.

    Type Parameters

    • T extends AnyJson = AnyJson

    Parameters

    • json: JsonMap

      The JsonMap tree to search for elements of the given name.

    • name: string

      The name of elements to search for.

    Returns T[]