Skip to content

Instantly share code, notes, and snippets.

@vldvel
Created March 28, 2018 07:01
Show Gist options
  • Save vldvel/3399d8ee2d88221d06833c3dd0778b85 to your computer and use it in GitHub Desktop.
Save vldvel/3399d8ee2d88221d06833c3dd0778b85 to your computer and use it in GitHub Desktop.
MutationObserver disconnect takeRecords
// stop observing
observer.disconnect();
// empties observer instance and returns records
observer.takeRecords(); // -> MutationRecords
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment