Documentation
    Preparing search index...

    Function asJsonObject

    • Validates a value as a JSON object and returns a deep-frozen copy.

      The object form of cloneJsonValue, exported for the same reason as validateVector3Document: a component serializer's payload is nearly always an object, and its deserialize has to say so before reading fields.

      Parameters

      • value: unknown

        the candidate object

      • path: string

        a dotted path used in error messages

      Returns JsonObject

      the frozen deep copy

      TypeError if the value is not a plain JSON object