@dxos/echo
    Preparing search index...

    Variable getConst

    get: {
        <T>(
            annotation: Annotation.Annotation<T>,
        ): (target: Entity.Unknown | Entity.Snapshot) => Option<T>;
        <T>(
            target: Entity.Unknown | Entity.Snapshot,
            annotation: Annotation.Annotation<T>,
        ): Option<T>;
    } = ...

    Get the value of an annotation from an entity instance or snapshot. For schema-level reads use the annotation instance method (e.g. ColorAnnotation.get(schema)). For getting an annotation value from a dictionary, use getDictionary.

    The value is read-only (schema types are readonly by default): to mutate an annotation (including in-place array splices) use Annotation.update or Annotation.set, which open a change transaction. A read-only return is sound regardless of context — the reactive proxy rejects mutation outside an Obj.update.

    Type declaration

    O(1) meta-dictionary read; returns the stored value without decoding or copying.