title: JSON Data loading Issue local storing
body: <p>I'm trying to make an incremental game for learning purposes, and I'm facing a problem when saving users data locally. </p>
  
  <p>For example, when I click on a button, it saves the value from the var "Food" :</p>
  
  <pre><code>localStorage.setItem("food",JSON.stringify(food));
  </code></pre>
  
  <p>And another button to load the save, linked to this function : </p>
  
  <pre><code>function loadFood() {
  
  document.getElementById("food").innerHTML = JSON.parse(localStorage.getItem("food"));
  
  }
  </code></pre>
  
  <p>However, my value Food is changing only when I press on the button. The value changes for like 1 second and then it goes back to 0. </p>
  
  <p>Is there any way to fix this? </p>