title: Knockout firing click binding on applyBindings
body: <p>Recently I've separated out ViewModel to a separate JavaScript file.</p>
  
  <pre><code>var Report = (function($) {
      var initialData = [];
      var viewModel = {
          reports: ko.observableArray(initialData),
          preview: function(path) {
              // preview report
          },
          otherFunctions: function() {}
      };
      return viewModel;
  })(jQuery);​
  </code></pre>
  
  <p>Here is the HTML and Knockout related code</p>
  
  <pre><code>&lt;script type="text/javascript" src="path/to/report/javascript"&gt;&lt;/script&gt;
  &lt;script type="text/javascript"&gt;
      $(document).ready(function () {
          ko.applyBindings(Report, document.body);
      });
  &lt;/script&gt;
  </code></pre>
  
  <p>HTML user interface has a button on which click is data bind to preview function in the view model</p>
  
  <pre><code>&lt;input type="button" name="Preview" id="Preview" class="btnPreview" 
      data-bind="click: Report.preview('url/to/report')" /&gt;
  </code></pre>
  
  <p><strong>Problem</strong> preview method is called when the following line execute in $(document).ready() function</p>
  
  <pre><code>ko.applyBindings(Report, document.body); 
  </code></pre>
  
  <p>That is without user clicking on the Preview button preview function is fired. What could be the reason for this behavior? The whole stuff was working fine when I'd view model JavaScript in the HTML page itself. </p>