Documentation
    Preparing search index...

    Interface MorphWeightsSerializerShape<T>

    The structural shape of @fourjs/serialization's ComponentSerializer<T> — declared here rather than imported because the frozen §3.1 matrix has no scene → serialization edge (that package sits above this one). The same documented duck-typing move @fourjs/motion's serializers make, with the same honest cost: nothing type-checks the two declarations against each other beyond the umbrella's registration call.

    interface MorphWeightsSerializerShape<T> {
        deserialize(data: JsonValue, node: unknown): T;
        serialize(component: T): JsonValue;
    }

    Type Parameters

    • T
    Index
    • Rebuilds the component from a payload. Attaching is the caller's job.

      Parameters

      Returns T

    • Produces the component's payload; must be representable JSON.

      Parameters

      • component: T

      Returns JsonValue