function loadData() {
  fetch('https://api.covidactnow.org/v2/states.json?apiKey=4ac37661a08a40b5a50cbe35eb941043').then(response => response.json()).then((data) => {
    const dataElement = document.getElementById('data-container');
    data.forEach((ind_data) => {
        dataElement.appendChild(createDataElement(ind_data));
        var linebreak = document.createElement("br");
        dataElement.appendChild(linebreak);
  		dataElement.appendChild(linebreak);
        
    })
  });

}
/**fetches coviddata from api and adds to DOM */
fetches coviddata from api and adds to DOM
fetches coviddata from api and adds to DOM
function loadData() {
  fetch('https://api.covidactnow.org/v2/states.json?apiKey=4ac37661a08a40b5a50cbe35eb941043').then(response => response.json()).then((data) => {
    const dataElement = document.getElementById('data-container');
    data.forEach((ind_data) => {
        dataElement.appendChild(createDataElement(ind_data));
        var linebreak = document.createElement("br");
        dataElement.appendChild(linebreak);
  		dataElement.appendChild(linebreak);
    })
  });
}
function loadData ( ) { fetch ( 'https://api.covidactnow.org/v2/states.json?apiKey=4ac37661a08a40b5a50cbe35eb941043' ) . then ( response => response . json ( ) ) . then ( ( data ) => { const dataElement = document . getElementById ( 'data-container' ) ; data . forEach ( ( ind_data ) => { dataElement . appendChild ( createDataElement ( ind_data ) ) ; var linebreak = document . createElement ( "br" ) ; dataElement . appendChild ( linebreak ) ; dataElement . appendChild ( linebreak ) ; } ) } ) ; }
fetches coviddata from api and adds to DOM
fetches coviddata from api and adds to DOM