title: Unable to Find Solution: JSON.parse: unexpected end of data at line 1 column 1
body: <p>I'm trying to build a basic React application that reaches out to an API to fetch quotes. The 'GET' request returns a string, however, when I try to parse that string to JSON is when I receive the error.</p>
  
  <p>Here's my function making the request: </p>
  
  <pre><code>const httpCallout = () =&gt; {
    const Http = new XMLHttpRequest();
  
    const endpoint = "http://quotesondesign.com/wp-json/posts?filter[orderby]=rand&amp;filter[posts_per_page]=1";
    Http.open("GET", endpoint, true);
    Http.send();
    let reply = "";
  
    Http.onreadystatechange = (e) =&gt;{
        console.log(JSON.parse(Http.response));
        //console.log(Http.response);
    }
    return reply;
  }
  </code></pre>
  
  <p>and the parsed response from the server:</p>
  
  <pre><code>[
    {
      "ID": 1286,
      "title": "Adrian Shaughnessy",
      "content": "&lt;p&gt;Graphic design has been likened to a wine glass. When we drink wine we barely notice the glass it&amp;#8217;s served in. It wouldn&amp;#8217;t be true to say that we don&amp;#8217;t care what glass we drink out of &amp;#8211; we wouldn&amp;#8217;t choose to drink a rare vintage out of a Tupperware mug, for example &amp;#8211; but it&amp;#8217;s the wine that matters, not the vessel it comes in.   &lt;/p&gt;\n",
      "link": "https://quotesondesign.com/adrian-shaughnessy/",
      "custom_meta": {
        "Source": "&lt;a href=\"http://observatory.designobserver.com/entry.html?entry=7257\"&gt;transcript&lt;/a&gt;"
      }
    }
  ]
  </code></pre>
  
  <p>I'm also looking for non-jQuery responses. Again, the full error the console is throwing is: <code>SyntaxError: JSON.parse: unexpected end of data at line 1 column 1 of the JSON data</code> and giving the error at the line <code>console.log(JSON.parse(Http.response));</code></p>