assets/script.js
// init - initialize page showing weather of last city searched or blank if no last city searched
initialize page showing weather of last city searched or blank if no last city searched
initialize page showing weather of last city searched or blank if no last city searched
function init() {
    currentCity = localStorage.getItem("lastCity") || "";
    if (currentCity == "") {
        resultsEl.addClass("invisible");
    } else {
        displayCities();
        requestWeather(currentCity);
    }
}
function init ( ) { currentCity = localStorage . getItem ( "lastCity" ) || "" ; if ( currentCity == "" ) { resultsEl . addClass ( "invisible" ) ; } else { displayCities ( ) ; requestWeather ( currentCity ) ; } }
init - initialize page showing weather of last city searched or blank if no last city searched
init - initialize page showing weather of last city searched or blank if no last city searched
// if previous queries stored, display in a list and request current weather