ObservableObject.makeRoot()
Turns this object into a root object that cannot be attached.
static makeRoot(object: ObservableObject): void;
Notes
- This method is used to mark an object as a ‘root’ object, which cannot be attached to another object. This also implies that any bindings cannot go beyond this object in the tree structure, and any bindings that are still unbound after an object is attached to the root object will result in an error.
- This method is called automatically on the app object.
Errors
This method throws an error if the object is already attached to another object.
Related
class ObservableObject
The base class of all observable objects, which can be placed into a tree structure to enable event handling and data binding.
