@managed

@managed

<T extends ManagedObject>(target: T, propertyKey: any): void

Managed object property decorator: amend decorated property to turn it into a managed reference to any other managed object (or managed list, map, or reference instance). This allows observers to handle events emitted by the referenced object (see ManagedObject.addObserver).

The decorated property immediately becomes undefined when the referenced object is destroyed (see ManagedObject.managedState).

See also: Concepts > Components