title: FileReader.OnLoad escalation in the code block
body: <p>I wrote 2 pieces of testing codes. They both triggered 'OK' message. Does it mean the OnLoad property (reference to a event handler upon data reading completed) gets escalated to the top of the code and gets called regardless its location?</p>
  
  <p>1st piece</p>
  
  <pre><code>        var selectedFile = event.target.files[0];           
          var reader = new FileReader();
          reader.onload = function() {alert('ok');};
          reader.readAsDataURL(selectedFile);
  </code></pre>
  
  <p>2nd piece</p>
  
  <pre><code>        var selectedFile = event.target.files[0];
          var reader = new FileReader();
          reader.readAsDataURL(selectedFile);
          reader.onload = function() {alert('ok');};
  </code></pre>