title: AJAX: Why does my http.readystate only return 4?
body: <p>I have a file folder set up to work with AJAX. I have a dummy json file:</p>
  
  <pre><code>{
      "tweets": [
          {
            "content": "hello"  
          },
          {
            "content": "world"  
          }
      ]
  }
  </code></pre>
  
  <p>The problem I'm having, is that when I console.log the <code>http</code> object, I keep getting a <code>readystate</code> of "4". But, I believe I'm supposed to get different ready states. This makes me think my code is wrong. </p>
  
  <p>I'm following along to this video on YouTube: <a href="https://www.youtube.com/watch?v=h0ZUpPiV1ac&amp;index=2&amp;list=PL4cUxeGkcC9jAhrjtZ9U93UMIhnCc44MH" rel="nofollow noreferrer">https://www.youtube.com/watch?v=h0ZUpPiV1ac&amp;index=2&amp;list=PL4cUxeGkcC9jAhrjtZ9U93UMIhnCc44MH</a></p>
  
  <p>Can someone explain why I can't seem to get the different ready states?</p>
  
  <pre><code>window.onload = function() {
  
  
      var http = new XMLHttpRequest();
  
  
      http.onreadystatechange = function() {
          console.log(http);
      }
  
      http.open('GET', 'data/tweets.json', true);
      http.send();
  
  }
  </code></pre>