<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Javascript on Build in Public</title><link>https://build.ralphmayr.com/tags/javascript/</link><description>Recent content in Javascript on Build in Public</description><generator>Hugo</generator><language>en-us</language><copyright>©️ Ralph Mayr 2026</copyright><lastBuildDate>Thu, 21 Aug 2025 00:00:00 +0000</lastBuildDate><atom:link href="https://build.ralphmayr.com/tags/javascript/index.xml" rel="self" type="application/rss+xml"/><item><title>Object.assign(...) in JavaScript helps with asynchronous updates</title><link>https://build.ralphmayr.com/posts/52-object-assign-in-javascript-helps-with-asynchronous-updates/</link><pubDate>Thu, 21 Aug 2025 00:00:00 +0000</pubDate><guid>https://build.ralphmayr.com/posts/52-object-assign-in-javascript-helps-with-asynchronous-updates/</guid><description>&lt;p&gt;In
&lt;a href="../51-websockets-more-than-tech-vanity/"&gt;WebSockets: More than tech vanity&lt;/a&gt;, I talked about the implicit user value of asynchronous UIs. Today, here&amp;rsquo;s a neat little JavaScript trick I hadn&amp;rsquo;t been aware of that makes implementing them a bit easier: &lt;code&gt;Object.assign(...)&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;Here&amp;rsquo;s the situation:&lt;/p&gt;
&lt;p&gt;Your Angular frontend initially fetches a list of items from the backend. Thanks to Angular&amp;rsquo;s powerful data binding, many components reference properties of these objects. Later, the backend sends an updated version of one of these items via WebSocket. What now?&lt;/p&gt;</description></item></channel></rss>