[webcomponents]: What callbacks do custom elements need?

Here are all the callbacks that we could think of:

* readyCallback (artist formerly known as "create") -- called when the
element is instantiated with generated constructor, createElement/NS
or shortly after it was instantiated and placed in a tree during
parser tree construction

* attributeChangedCallback -- synchronously called when an attribute
of an element is added, removed, or modified

* insertedCallback -- asynchronously called when an element is added
to document tree (TBD: is this called when parser is constructing the
tree?)

* removedCallback -- asynchronously called when an element is removed
from the document tree (except the situations when the document is
destroyed)

What do you think? Anything looks obviously
wrong/dangerous/crazy/exciting? Anything missing?

Received on Wednesday, 6 March 2013 22:06:10 UTC