examples/bower_components/polymer/polymer.js
function(node, listener) {
      var observer = new MutationObserver(function(mutations) {
        listener.call(this, observer, mutations);
        observer.disconnect();
      }.bind(this));
      observer.observe(node, {childList: true, subtree: true});
    }
function(node, listener) {
      var observer = new MutationObserver(function(mutations) {
        listener.call(this, observer, mutations);
        observer.disconnect();
      }.bind(this));
      observer.observe(node, {childList: true, subtree: true});
    }
function ( node , listener ) { var observer = new MutationObserver ( function ( mutations ) { listener . call ( this , observer , mutations ) ; observer . disconnect ( ) ; } . bind ( this ) ) ; observer . observe ( node , { childList : true , subtree : true } ) ; }
Register a one-time callback when a child-list or sub-tree mutation
occurs on node.

For persistent callbacks, call onMutation from your listener.

@method onMutation
@param Node {Node} node Node to watch for mutations.
@param Function {Function} listener Function to call on mutation. The function is invoked as `listener.call(this, observer, mutations);` where `observer` is the MutationObserver that triggered the notification, and `mutations` is the native mutation list.
Register a one - time callback when a child - list or sub - tree mutation occurs on node .