atom/space-pen — pull request #56 by nathansobo (2014-10-30 21:20:57+00:00)
Title: Breaking changes to make compatible with a jQuery-free Atom-core

We are removing jQuery from Atom core in favor of custom elements and direct use of native DOM APIs. SpacePen will continue to work, but a few *slight* breaking changes are required for compatibility in this new world:

* Lifecycle hooks: The previous implementation relied on all DOM manipulation being performed via jQuery, which is no longer happening. The new implementation takes advantage of custom element lifecycle hooks, but is unable to present the exact same semantics.
* `afterAttach` replaced with `attached`: Previously you were notified when an element was attached to another detached element *and* when it was attached to the DOM itself. Now you are only informed of actual DOM attachments via the `attached` hook. The `onDOM` argument has been eliminated.
* `beforeRemove` replaced with `detached`: Previously no hook was fired when a node was "detached" via jQuery. Only when it was "removed". DOM APIs don't make that distinction so your hook will always be called when the element is detached for any reason.
* `$.fn.command` now integrates directly with the new Atom command registry. This method should work as it did before, but you can no longer pass a selector or option hash.

I also took the opportunity to implement `$.fn.view` and `$.fn.containingView` in terms of expando properties on the DOM nodes to avoid the slowness of `$.fn.data` lookups. That should not affect external behavior.

One open question: Should we port over the tooltip helpers from Atom? I'm leaning toward no, and finding a different solution for tooltips.