HTML5 includes a concept of "mutation observers" to monitor changes to the browser's DOM.
Your observer callback will be passed data which looks a lot like DOM tree snippets. I don't know if they are exactly this or how they work really.
But when you are writing code to interact with a 3rd party site over which you have no control, say with a Greasemonkey script or Google Chrome user script, you have to inspect the tree of elements passed in to find which information is relevant to you.
This is much simpler with selectors, just like working with any DOM, than walking the tree manually, especially for cross-browser code.
Is there a way to use jQuery selectors with the data passed to HTML5 mutation observer callbacks?
See Question&Answers more detail:os