Skip to content

Commit

Permalink
provide the mutation records to onMutation listeners
Browse files Browse the repository at this point in the history
  • Loading branch information
Scott J. Miles committed Oct 4, 2013
1 parent 7f1206a commit 7d11c03
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/instance/base.js
Original file line number Diff line number Diff line change
Expand Up @@ -172,8 +172,8 @@
}
},
onMutation: function(node, listener) {
var observer = new MutationObserver(function() {
listener.call(this, observer);
var observer = new MutationObserver(function(mutations) {
listener.call(this, observer, mutations);
observer.disconnect();
}.bind(this));
observer.observe(node, {childList: true, subtree: true});
Expand Down

0 comments on commit 7d11c03

Please sign in to comment.