How to change a property on an object without mutating it?
<pre><code>const a = {x: &quot;Hi&quot;, y: &quot;Test&quot;}
const b = ???
// b = {x: &quot;Bye&quot;, y: &quot;Test&quot;}
// a = {x: &quot;Hi&quot;, y: &quot;Test&quot;}
</code></pre>
<p>How can I set <code>b.x</code> to <code>&quot;Bye&quot;</code> without mutating a?</p>