Ember manages the lifecycles and lifetimes of many built in constructs, such as components, and does so in a hierarchical way - when a parent component is destroyed, all of its children are destroyed as well.
This destroyables API exposes the basic building blocks for destruction:
- registering a function to be ran when an object is destroyyed
- checking if an object is in a destroying state
- associate an object as a child of another so that the child object will be destroyed when the associated parent object is destroyed.