title: JQuery: Detect when element and all children are loaded
body: <p>I'd like to have code executed when a particular element and all of it's children are in the DOM. I know how to poll for the desired element's existence, or even better, to use a <code>MutationObserver</code>, but the desired element is itself rather large and I can't be sure that all of it's children are fully loaded simply based on it existing.</p>
  
  <p>I could wait for <code>ready</code> which is called when <em>all</em> the DOM is loaded, but the page usually takes a rather long time to load. In the interests of speed i'd like to know without necessarily waiting for <code>$(document).ready()</code>.</p>
  
  <p>I did find the <code>on</code> function, I love the fact that it will be called for elements which don't even exist yet:</p>
  
  <p><code>$(document).on('SomeEvent', '#desiredElem', handler);</code></p>
  
  <p>...however I don't know of an event which is fired for an html element being fully in the DOM.</p>
  
  <p>My script is being injected into the browser, and I know from logging that it's running a long time before <code>$(document).ready()</code> or <code>DOMContentLoaded</code>. Basically i'd like to take advantage of that. I can't add <code>&lt;script&gt;</code> tags to the HTML, unfortunately.</p>
  
  <p>On a side note, an event for an object existing would be interesting. It would save me from having to use <code>MutationObserver</code>.</p>