title: How to use jQuery in a Knockout.js Template?
body: <p>I'm trying to target an element using jQuery which is embedded in one of my knockout templates:</p>
  
  <pre><code>&lt;script type="text/html" id="video-file-template"&gt;
      &lt;div class="video" data-bind="attr: { 'data-index': $index }"&gt;
      &lt;/div&gt;
  &lt;/script&gt;
  </code></pre>
  
  <p>Yet, when I attempt to select <code>$('.video')</code> using jQuery, wrapped in a document ready function, I get an object with a length of 0 returned:</p>
  
  <pre><code>$(document).ready(function() {
      console.log($('.video')); // Returns an object with a length of 0
  });
  </code></pre>
  
  <p>Why is this? Is it because the element is not part of the DOM when my jQuery script is evaluated? If so, how can I target the element when it is loaded into the DOM via Knockout.js?</p>