Netflix / x-element

A dead simple starting point for custom elements.
Apache License 2.0
28 stars 12 forks source link

Switch order of observer arguments #26

Closed theengineear closed 3 years ago

theengineear commented 5 years ago

Currently, you get the values in the following order: oldValue, newValue

This was done to match attributeChangedCallback. However, in practice this is not as ergonomic. It's often the case that you do not care about the previous value, causing code like this: myObserver(_, value).

This is pulled into a separate issue since it will cause a sweeping change of all code leveraging observers.