title: Overwrite and save JavaScript variable values permanently
body: <p>I have a JavaScript file with an Object inside. What I'm trying to do is change the Object variable values using another JavaScript file. However if i change the values and close and reopen the JavaScript file with an Object inside, the values revert back to its original value. </p>
  
  <p>Is there any way to change the Object values and save them, so when i close and reopen the file it has the new values instead of the old ones.</p>
  
  <p>JavaScript file with an Object:</p>
  
  <pre><code>var datax = {
      Temperature: 20,
      Light_Intensity: 40,
      button: 0,
      max1: 0,
      Counter: 0
  };
  </code></pre>
  
  <p>A second JavaScript file that changes datax Object values:</p>
  
  <pre><code>//Temperature
  max = max / 655.34;
  max = Math.round(max);
  datax.max1 = max; //Changes the datax object max1 value
  $('#temp').html(datax["max1"] + "&amp;deg;C");
  </code></pre>