$("#hour8 .description").val(localStorage.getItem("hour8"));
$("#hour9 .description").val(localStorage.getItem("hour9"));
$("#hour10 .description").val(localStorage.getItem("hour10"));
this is the current code that I have minus 8 more hours, how can I loop through this to clean it up?
If you're trying to reduce the amount of duplicated code you could loop through each hour and programatically target the html element and get the data for that element from localStorage.
[1,2,3,4,5,6,7,8,9,10].forEach(hour => {
$(`#hour${hour} .description`).val(localStorage.getItem(`hour${hour}`));
})