function parse(url, successCallback, failCallback) {
  const xhr = new XMLHttpRequest();
  xhr.onload = () => {
    if (xhr.status === 200) {
      parseData(xhr.responseText, successCallback, failCallback);
    } else if (failCallback) {
      failCallback(`Data request failed with reason: ${xhr.statusText}`);
    }
  };
  xhr.open("GET", url);
  xhr.send(null);
}
/**
 * Parse delimited data from file using native AJAX request.
 * @public
 * @param  {string} url                {Data input URL to be parsed.}
 * @param  {function} successCallback  {Callback in case of success.}
 * @param  {function} failCallback     {Callback in case of fail.}
 * @return {void}
 */
Parse delimited data from file using native AJAX request.
Parse delimited data from file using native AJAX request .
function parse(url, successCallback, failCallback) {
  const xhr = new XMLHttpRequest();
  xhr.onload = () => {
    if (xhr.status === 200) {
      parseData(xhr.responseText, successCallback, failCallback);
    } else if (failCallback) {
      failCallback(`Data request failed with reason: ${xhr.statusText}`);
    }
  };
  xhr.open("GET", url);
  xhr.send(null);
}
function parse ( url , successCallback , failCallback ) { const xhr = new XMLHttpRequest ( ) ; xhr . onload = ( ) => { if ( xhr . status === 200 ) { parseData ( xhr . responseText , successCallback , failCallback ) ; } else if ( failCallback ) { failCallback ( ` ${ xhr . statusText } ` ) ; } } ; xhr . open ( "GET" , url ) ; xhr . send ( null ) ; }
Parse delimited data from file using native AJAX request.
Parse delimited data from file using native AJAX request .