assets/script.js
// saves to local storage and retrieves last search
saves to local storage and retrieves last search
saves to local storage and retrieves last search
function saveToLocal(cityInput) {
    var inputData = JSON.parse(localStorage.getItem("cityInput")) || [];
    inputData.push(cityInput);
    localStorage.setItem("cityInput", JSON.stringify(inputData));
}
function saveToLocal ( cityInput ) { var inputData = JSON . parse ( localStorage . getItem ( "cityInput" ) ) || [ ] ; inputData . push ( cityInput ) ; localStorage . setItem ( "cityInput" , JSON . stringify ( inputData ) ) ; }
saves to local storage and retrieves last search
saves to local storage and retrieves last search