title: How to let variable become immutable after one change?
body: <p>first value from event data:</p>
  
  <pre><code>A = 100;
  start_value = A;
  start_value = 100
  </code></pre>
  
  <p>but A is constantly changing due to <code>JSON.parse(evt.data)</code> from sensors</p>
  
  <p>so after a while if:</p>
  
  <pre><code>A = 500
  start_value = 500
  </code></pre>
  
  <p>How do i fix start_value = the first JSON data from websockets?</p>
  
  <p>I've tried <code>Object.freeze()</code>, <code>Object.assign()</code>, however, the problem is since start_value is derived from A, it will always be changed. Is it possible to fix the start_value using the first value of A?</p>