@salesforce/ts-types
    Preparing search index...

    Function assertAnyJson

    • Narrows an unknown value to an AnyJson if it is type-compatible, or returns undefined otherwise.

      See also caveats noted in isAnyJson.

      Parameters

      • value: unknown

        The value to test.

      • Optionalmessage: string

        The error message to use if value is not type-compatible.

      Returns asserts value is AnyJson

      AssertionFailedError If the value was not a JSON value type.