<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: YASHWANTH REDDY K</title>
    <description>The latest articles on DEV Community by YASHWANTH REDDY K (@yashwanth_reddyk_ad8c405).</description>
    <link>https://dev.to/yashwanth_reddyk_ad8c405</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3816174%2Fb12a7536-00c8-40d2-9ca5-564a89eda976.png</url>
      <title>DEV Community: YASHWANTH REDDY K</title>
      <link>https://dev.to/yashwanth_reddyk_ad8c405</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/yashwanth_reddyk_ad8c405"/>
    <language>en</language>
    <item>
      <title>I Built a Spatial Audio Radar ft. Vibe Code Arena</title>
      <dc:creator>YASHWANTH REDDY K</dc:creator>
      <pubDate>Mon, 27 Apr 2026 09:24:02 +0000</pubDate>
      <link>https://dev.to/yashwanth_reddyk_ad8c405/i-built-a-spatial-audio-radar-ft-vibe-code-arena-2jho</link>
      <guid>https://dev.to/yashwanth_reddyk_ad8c405/i-built-a-spatial-audio-radar-ft-vibe-code-arena-2jho</guid>
      <description>&lt;p&gt;It looks like a visual problem at first.&lt;/p&gt;

&lt;p&gt;A circle in the center.&lt;br&gt;
Click somewhere → a glowing ring expands.&lt;br&gt;
A sound plays.&lt;/p&gt;

&lt;p&gt;Nice little sci-fi UI.&lt;/p&gt;

&lt;p&gt;But the moment you try to make the sound feel like it’s actually coming from where you clicked…&lt;/p&gt;

&lt;p&gt;Everything changes.&lt;/p&gt;

&lt;p&gt;Because now you’re not building a visualizer.&lt;/p&gt;

&lt;p&gt;You’re building a &lt;strong&gt;coordinate system that humans can hear&lt;/strong&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  The illusion breaks immediately
&lt;/h2&gt;

&lt;p&gt;You can get something working fast:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;audio.play();
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Click → sound.&lt;/p&gt;

&lt;p&gt;Done.&lt;/p&gt;

&lt;p&gt;But it doesn’t matter where you click.&lt;/p&gt;

&lt;p&gt;Left side. Right side. Edge. Center.&lt;/p&gt;

&lt;p&gt;It all sounds the same.&lt;/p&gt;

&lt;p&gt;And that’s the problem.&lt;/p&gt;

&lt;p&gt;Because visually, you’re telling the user:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Sound originates from &lt;em&gt;this exact point&lt;/em&gt;”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;But aurally, you’re saying:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Actually, it comes from nowhere in particular”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That mismatch kills the illusion instantly.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F68aqoebplty3x29jjij6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F68aqoebplty3x29jjij6.png" alt=" " width="800" height="363"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  This isn’t about sound playback
&lt;/h2&gt;

&lt;p&gt;It’s about &lt;strong&gt;spatial mapping&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;You don’t just need to play audio.&lt;/p&gt;

&lt;p&gt;You need to answer:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Where is this sound located relative to the listener?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;In 2D, that reduces to something simple:&lt;/p&gt;

&lt;p&gt;Left ↔ Right&lt;/p&gt;

&lt;p&gt;Which maps perfectly to stereo panning.&lt;/p&gt;

&lt;h2&gt;
  
  
  The mistake most implementations make
&lt;/h2&gt;

&lt;p&gt;They treat the click position as absolute.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const pan = mouseX / width;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This gives you a value between 0 and 1.&lt;/p&gt;

&lt;p&gt;But audio panning expects:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;-1 → full left  
 0 → center  
 1 → full right
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;So your mapping is already wrong.&lt;/p&gt;

&lt;p&gt;Even if the math “works”.&lt;/p&gt;

&lt;h2&gt;
  
  
  The correct mental model
&lt;/h2&gt;

&lt;p&gt;Everything is relative to the &lt;strong&gt;center of the radar&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Not the screen.&lt;/p&gt;

&lt;p&gt;So you calculate:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const centerX = rect.left + rect.width / 2;
const dx = (mouseX - centerX) / (rect.width / 2);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now &lt;code&gt;dx&lt;/code&gt; ranges from:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;-1 → far left  
  0 → center  
  1 → far right
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This one line fixes the entire spatial illusion.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fg57me6r9w4o1sqkcbe58.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fg57me6r9w4o1sqkcbe58.png" alt=" " width="800" height="380"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The sound engine becomes directional
&lt;/h2&gt;

&lt;p&gt;Now instead of:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;audio.play();

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You route it through a panner:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const panner = ctx.createStereoPanner();
panner.pan.value = dx;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And suddenly…&lt;/p&gt;

&lt;p&gt;Clicks on the left &lt;em&gt;sound&lt;/em&gt; left.&lt;/p&gt;

&lt;p&gt;Clicks on the right &lt;em&gt;sound&lt;/em&gt; right.&lt;/p&gt;

&lt;p&gt;The system feels grounded.&lt;/p&gt;

&lt;h2&gt;
  
  
  The visual pulse is not decoration
&lt;/h2&gt;

&lt;p&gt;It’s confirmation&lt;/p&gt;

&lt;p&gt;When you click, you create a ring:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ring.style.transform = "scale(1.5)";
ring.style.opacity = 0;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It expands. Fades.&lt;/p&gt;

&lt;p&gt;But the important part is not the animation.&lt;/p&gt;

&lt;p&gt;It’s that it originates from the exact click point.&lt;/p&gt;

&lt;p&gt;Because now:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;your eyes see origin&lt;/li&gt;
&lt;li&gt;your ears hear direction&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And they agree.&lt;/p&gt;

&lt;p&gt;That agreement is what makes the system feel real.&lt;/p&gt;

&lt;h2&gt;
  
  
  The center ripple reveals something subtle
&lt;/h2&gt;

&lt;p&gt;Every click also triggers a center pulse.&lt;/p&gt;

&lt;p&gt;At first, it feels redundant.&lt;/p&gt;

&lt;p&gt;Why animate the center if the click is elsewhere?&lt;/p&gt;

&lt;p&gt;Because it anchors the system.&lt;/p&gt;

&lt;p&gt;It reminds the user:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“You are here. Everything is relative to this point.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Without it, the radar feels like a canvas.&lt;/p&gt;

&lt;p&gt;With it, it feels like a system.&lt;/p&gt;

&lt;h2&gt;
  
  
  The drone toggle is not just a feature
&lt;/h2&gt;

&lt;p&gt;It’s a baseline&lt;/p&gt;

&lt;p&gt;When everything is silent, each click feels isolated.&lt;/p&gt;

&lt;p&gt;Disconnected.&lt;/p&gt;

&lt;p&gt;Add a continuous ambient loop:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;drone.loop = true;
drone.play();
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now clicks exist &lt;em&gt;within&lt;/em&gt; a soundscape.&lt;/p&gt;

&lt;p&gt;And spatial differences become more noticeable.&lt;/p&gt;

&lt;p&gt;Because there’s contrast.&lt;/p&gt;

&lt;h2&gt;
  
  
  Timing becomes perception
&lt;/h2&gt;

&lt;p&gt;If the sound plays even slightly late…&lt;/p&gt;

&lt;p&gt;The illusion breaks.&lt;/p&gt;

&lt;p&gt;Visuals are immediate.&lt;/p&gt;

&lt;p&gt;Audio must match.&lt;/p&gt;

&lt;p&gt;Which is why you avoid delays and keep everything inside the same event frame.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fb6tpwv4xhfeln5ghonww.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fb6tpwv4xhfeln5ghonww.png" alt=" " width="800" height="375"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The radar is secretly a coordinate system
&lt;/h2&gt;

&lt;p&gt;That circle in the center?&lt;/p&gt;

&lt;p&gt;It’s not just visual.&lt;/p&gt;

&lt;p&gt;It defines:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;bounds&lt;/li&gt;
&lt;li&gt;center&lt;/li&gt;
&lt;li&gt;interaction area&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Everything depends on its dimensions:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const rect = radar.getBoundingClientRect();
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If this is off…&lt;/p&gt;

&lt;p&gt;Your spatial mapping drifts.&lt;/p&gt;

&lt;p&gt;And the user feels it.&lt;/p&gt;

&lt;p&gt;Even if they can’t explain why.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where most implementations go wrong
&lt;/h2&gt;

&lt;p&gt;Not in sound.&lt;/p&gt;

&lt;p&gt;Not in visuals.&lt;/p&gt;

&lt;p&gt;In &lt;strong&gt;alignment&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;They:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;calculate pan from screen width instead of radar&lt;/li&gt;
&lt;li&gt;misplace center&lt;/li&gt;
&lt;li&gt;delay audio playback&lt;/li&gt;
&lt;li&gt;desync visuals and sound&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Individually, these are small issues.&lt;/p&gt;

&lt;p&gt;Together, they break immersion.&lt;/p&gt;

&lt;h2&gt;
  
  
  What shows up in Vibe Code Arena
&lt;/h2&gt;

&lt;p&gt;This challenge creates a very specific divide.&lt;/p&gt;

&lt;p&gt;One model builds:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;nice visuals&lt;/li&gt;
&lt;li&gt;working sound&lt;/li&gt;
&lt;li&gt;basic interaction&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;But sound feels disconnected from position.&lt;/p&gt;

&lt;p&gt;Another model aligns everything:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;correct center-relative mapping&lt;/li&gt;
&lt;li&gt;immediate audio feedback&lt;/li&gt;
&lt;li&gt;synchronized visuals&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now the system feels &lt;em&gt;spatial&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The human version usually does one thing right
&lt;/h2&gt;

&lt;p&gt;It treats the center as sacred.&lt;/p&gt;

&lt;p&gt;Everything is calculated relative to it.&lt;/p&gt;

&lt;p&gt;Because once that’s correct…&lt;/p&gt;

&lt;p&gt;Everything else falls into place.&lt;/p&gt;

&lt;h2&gt;
  
  
  The part you don’t expect
&lt;/h2&gt;

&lt;p&gt;After building this, you stop seeing:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“click → play sound”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And start seeing:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“input → spatial mapping → audio perception → visual confirmation”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That pipeline is the real system.&lt;/p&gt;

&lt;h2&gt;
  
  
  The shift
&lt;/h2&gt;

&lt;p&gt;You stop thinking:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“how do I play sound?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And start thinking:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“how do I place sound in space?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That’s a very different problem.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fiuisnopxgksebccefvu4.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fiuisnopxgksebccefvu4.png" alt=" " width="800" height="449"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  If you want to explore this properly
&lt;/h2&gt;

&lt;p&gt;Don’t just click around.&lt;/p&gt;

&lt;p&gt;Test it intentionally:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;click extreme left/right edges&lt;/li&gt;
&lt;li&gt;click near center&lt;/li&gt;
&lt;li&gt;resize the window&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Watch how your mapping behaves.&lt;/p&gt;

&lt;p&gt;That’s where inaccuracies show up.&lt;/p&gt;

&lt;p&gt;Because this system doesn’t fail loudly.&lt;/p&gt;

&lt;p&gt;It fails in how &lt;em&gt;convincing&lt;/em&gt; it feels.&lt;/p&gt;

&lt;p&gt;And that’s much harder to debug.&lt;/p&gt;

&lt;p&gt;👉Try it out here: &lt;a href="https://vibecodearena.ai/share/c73a3887-794c-4012-a0af-f448f2a137d6" rel="noopener noreferrer"&gt;https://vibecodearena.ai/share/c73a3887-794c-4012-a0af-f448f2a137d6&lt;/a&gt;&lt;/p&gt;

</description>
      <category>llm</category>
      <category>ai</category>
      <category>vibecodearena</category>
      <category>hackerearth</category>
    </item>
    <item>
      <title>I Built a Generative Poster Tool ft. Vibe Code Arena</title>
      <dc:creator>YASHWANTH REDDY K</dc:creator>
      <pubDate>Sun, 26 Apr 2026 14:30:41 +0000</pubDate>
      <link>https://dev.to/yashwanth_reddyk_ad8c405/i-built-a-generative-poster-tool-ft-vibe-code-arena-44nf</link>
      <guid>https://dev.to/yashwanth_reddyk_ad8c405/i-built-a-generative-poster-tool-ft-vibe-code-arena-44nf</guid>
      <description>&lt;p&gt;There’s a very specific kind of disappointment that happens with generative design tools.&lt;/p&gt;

&lt;p&gt;You click “Generate.”&lt;/p&gt;

&lt;p&gt;Shapes appear. Colors shuffle. Layout changes.&lt;/p&gt;

&lt;p&gt;Technically, it’s working.&lt;/p&gt;

&lt;p&gt;But visually?&lt;/p&gt;

&lt;p&gt;It looks like someone dropped geometry on the screen and walked away.&lt;/p&gt;

&lt;p&gt;That’s the trap.&lt;/p&gt;

&lt;p&gt;Because randomness alone doesn’t create design.&lt;/p&gt;

&lt;p&gt;It creates noise.&lt;/p&gt;

&lt;p&gt;And this challenge — building a “Generative Abstract Poster Creator” — quietly forces you to confront that.&lt;/p&gt;

&lt;h2&gt;
  
  
  The first version always lies to you
&lt;/h2&gt;

&lt;p&gt;You start simple.&lt;/p&gt;

&lt;p&gt;A loop:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;for (let i = 0; i &amp;lt; 15; i++) {
  createRandomShape();
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Each shape gets:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;random position&lt;/li&gt;
&lt;li&gt;random size&lt;/li&gt;
&lt;li&gt;random color&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It feels productive.&lt;/p&gt;

&lt;p&gt;Until you actually look at the result.&lt;/p&gt;

&lt;p&gt;Everything overlaps awkwardly.&lt;br&gt;
Spacing feels accidental.&lt;br&gt;
Nothing aligns.&lt;/p&gt;

&lt;p&gt;There’s no visual rhythm.&lt;/p&gt;

&lt;p&gt;Just entropy.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fwpatqye47hjpgaws9rxu.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fwpatqye47hjpgaws9rxu.png" alt=" " width="800" height="367"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  The realization hits fast
&lt;/h2&gt;

&lt;p&gt;Design is not randomness.&lt;/p&gt;

&lt;p&gt;It’s &lt;strong&gt;controlled randomness inside constraints&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;And the moment you introduce constraints…&lt;/p&gt;

&lt;p&gt;Everything changes.&lt;/p&gt;
&lt;h2&gt;
  
  
  The grid is the invisible system
&lt;/h2&gt;

&lt;p&gt;The requirement says:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Snap shapes to a 4x4 or 8x8 grid&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;At first, that sounds like a layout detail.&lt;/p&gt;

&lt;p&gt;It isn’t.&lt;/p&gt;

&lt;p&gt;It’s the entire system.&lt;/p&gt;

&lt;p&gt;Instead of placing shapes anywhere:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const x = Math.random() * width;
const y = Math.random() * height;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You snap them:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const cell = 50;

const x = Math.floor(Math.random() * 8) * cell;
const y = Math.floor(Math.random() * 12) * cell;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now every shape aligns to an invisible structure.&lt;/p&gt;

&lt;p&gt;And suddenly…&lt;/p&gt;

&lt;p&gt;The output starts looking intentional.&lt;/p&gt;

&lt;h2&gt;
  
  
  This is where things get interesting
&lt;/h2&gt;

&lt;p&gt;You haven’t changed:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;number of shapes&lt;/li&gt;
&lt;li&gt;types of shapes&lt;/li&gt;
&lt;li&gt;randomness&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You’ve only added &lt;em&gt;constraint&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;And yet the result feels like design.&lt;/p&gt;

&lt;p&gt;Because human perception loves alignment.&lt;/p&gt;

&lt;p&gt;Even when it’s not obvious.&lt;/p&gt;

&lt;h2&gt;
  
  
  Shapes are not equal
&lt;/h2&gt;

&lt;p&gt;Another mistake shows up quickly.&lt;/p&gt;

&lt;p&gt;You treat all shapes the same.&lt;/p&gt;

&lt;p&gt;Circles, squares, triangles, lines.&lt;/p&gt;

&lt;p&gt;Uniform probability.&lt;/p&gt;

&lt;p&gt;But real compositions don’t work like that.&lt;/p&gt;

&lt;p&gt;They have hierarchy.&lt;/p&gt;

&lt;p&gt;Weight.&lt;/p&gt;

&lt;p&gt;Balance.&lt;/p&gt;

&lt;p&gt;So you start biasing:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const type = weightedRandom([
  "circle",
  "square",
  "triangle",
  "line"
]);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now some shapes appear more often.&lt;/p&gt;

&lt;p&gt;Others become accents.&lt;/p&gt;

&lt;p&gt;And the composition gains structure.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fgfllqez3zgkfepe86eck.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fgfllqez3zgkfepe86eck.png" alt=" " width="800" height="375"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Size is where chaos sneaks back in
&lt;/h2&gt;

&lt;p&gt;Even with a grid, random sizes can break everything.&lt;/p&gt;

&lt;p&gt;A giant circle can overpower the layout.&lt;/p&gt;

&lt;p&gt;Tiny shapes can disappear.&lt;/p&gt;

&lt;p&gt;So you constrain size too:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const sizes = [1, 2, 3]; // grid units
const size = sizes[Math.floor(Math.random() * sizes.length)];
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now everything scales relative to the grid.&lt;/p&gt;

&lt;p&gt;No rogue elements.&lt;/p&gt;

&lt;h2&gt;
  
  
  The color palette is doing more than styling
&lt;/h2&gt;

&lt;p&gt;Switching between:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Bauhaus&lt;/li&gt;
&lt;li&gt;Forest&lt;/li&gt;
&lt;li&gt;Cyber&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Sounds like a theme toggle.&lt;/p&gt;

&lt;p&gt;But it’s actually controlling &lt;em&gt;contrast relationships&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;If you randomly pick any color:&lt;/p&gt;

&lt;p&gt;You get clashes.&lt;/p&gt;

&lt;p&gt;If you pick from a curated palette:&lt;/p&gt;

&lt;p&gt;You get harmony.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const palette = ["#ff0000", "#0000ff", "#ffd500"];
const color = palette[Math.floor(Math.random() * palette.length)];
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This tiny constraint removes 90% of bad outcomes.&lt;/p&gt;

&lt;h2&gt;
  
  
  Overlap is not a bug
&lt;/h2&gt;

&lt;p&gt;It’s a feature — if handled correctly&lt;/p&gt;

&lt;p&gt;When shapes overlap, things can look messy.&lt;/p&gt;

&lt;p&gt;Unless you control how they blend.&lt;/p&gt;

&lt;p&gt;This is where:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;shape {
  mix-blend-mode: multiply;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;changes everything.&lt;/p&gt;

&lt;p&gt;Now overlaps create &lt;em&gt;new colors&lt;/em&gt; instead of visual clutter.&lt;/p&gt;

&lt;p&gt;It feels intentional.&lt;/p&gt;

&lt;p&gt;Almost printed.&lt;/p&gt;

&lt;p&gt;Without this, your design looks like layers.&lt;/p&gt;

&lt;p&gt;With it, it looks like composition.&lt;/p&gt;

&lt;h2&gt;
  
  
  The poster is not just a container
&lt;/h2&gt;

&lt;p&gt;That 400x600 rectangle?&lt;/p&gt;

&lt;p&gt;It defines proportion.&lt;/p&gt;

&lt;p&gt;Which defines everything inside it.&lt;/p&gt;

&lt;p&gt;If you don’t respect boundaries:&lt;/p&gt;

&lt;p&gt;Shapes overflow.&lt;/p&gt;

&lt;p&gt;Edges feel accidental.&lt;/p&gt;

&lt;p&gt;So you enforce limits:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;x = Math.min(x, width - shapeWidth);
y = Math.min(y, height - shapeHeight);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now nothing escapes.&lt;/p&gt;

&lt;p&gt;Everything feels contained.&lt;/p&gt;

&lt;p&gt;Containment is what makes it feel like a “poster”&lt;/p&gt;

&lt;p&gt;Not just a canvas.&lt;/p&gt;

&lt;h2&gt;
  
  
  Hover interactions reveal something deeper
&lt;/h2&gt;

&lt;p&gt;Adding a tooltip:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;coordinates&lt;/li&gt;
&lt;li&gt;dimensions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Feels like a small feature.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;el.onmouseenter = () =&amp;gt; showTooltip(x, y, w, h);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;But it exposes the system underneath.&lt;/p&gt;

&lt;p&gt;Now users can &lt;em&gt;see the grid&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Even if it’s invisible.&lt;/p&gt;

&lt;p&gt;And once they see it…&lt;/p&gt;

&lt;p&gt;The randomness feels less random.&lt;/p&gt;

&lt;p&gt;More deliberate.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fb2ngfz87yz79nh1ibd2w.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fb2ngfz87yz79nh1ibd2w.png" alt=" " width="800" height="385"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The “Generate” button is misleading
&lt;/h2&gt;

&lt;p&gt;It sounds like a trigger.&lt;/p&gt;

&lt;p&gt;But it’s actually a reset.&lt;/p&gt;

&lt;p&gt;Each click:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;destroys the previous composition&lt;/li&gt;
&lt;li&gt;creates a new one&lt;/li&gt;
&lt;li&gt;reuses the same rules&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That consistency is important.&lt;/p&gt;

&lt;p&gt;Because if rules change between generations…&lt;/p&gt;

&lt;p&gt;The system feels unstable.&lt;/p&gt;

&lt;h2&gt;
  
  
  What shows up in Vibe Code Arena
&lt;/h2&gt;

&lt;p&gt;This challenge reveals something subtle.&lt;/p&gt;

&lt;p&gt;Not who can generate shapes.&lt;/p&gt;

&lt;p&gt;But who understands &lt;strong&gt;design systems&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;One model builds:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;fully random placement&lt;/li&gt;
&lt;li&gt;random colors&lt;/li&gt;
&lt;li&gt;no constraints&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It technically satisfies requirements.&lt;/p&gt;

&lt;p&gt;But outputs feel chaotic.&lt;/p&gt;

&lt;p&gt;Forgettable.&lt;/p&gt;

&lt;p&gt;Another model introduces:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;grid snapping&lt;/li&gt;
&lt;li&gt;palette constraints&lt;/li&gt;
&lt;li&gt;size normalization&lt;/li&gt;
&lt;li&gt;blending modes&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now outputs feel… curated.&lt;/p&gt;

&lt;p&gt;Even though they’re still random.&lt;/p&gt;

&lt;h2&gt;
  
  
  The human version usually leans into restraint
&lt;/h2&gt;

&lt;p&gt;Not more features.&lt;/p&gt;

&lt;p&gt;Not more randomness.&lt;/p&gt;

&lt;p&gt;Just tighter rules.&lt;/p&gt;

&lt;p&gt;Because good generative design is not about freedom.&lt;/p&gt;

&lt;p&gt;It’s about &lt;strong&gt;guided variation&lt;/strong&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The strange shift that happens
&lt;/h2&gt;

&lt;p&gt;At some point, you stop thinking:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“How do I generate more variety?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And start thinking:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“How do I prevent bad outcomes?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That’s when your system matures.&lt;/p&gt;

&lt;p&gt;Because the goal isn’t infinite randomness.&lt;/p&gt;

&lt;p&gt;It’s consistently &lt;em&gt;good enough&lt;/em&gt; randomness.&lt;/p&gt;

&lt;h2&gt;
  
  
  The part you don’t expect
&lt;/h2&gt;

&lt;p&gt;After building this, you start noticing something.&lt;/p&gt;

&lt;p&gt;A lot of “design tools” are just:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;randomness&lt;/li&gt;
&lt;li&gt;with weak constraints&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Which is why their outputs feel generic.&lt;/p&gt;

&lt;p&gt;The difference between:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;amateur generative design&lt;/li&gt;
&lt;li&gt;and professional-looking output&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Isn’t complexity.&lt;/p&gt;

&lt;p&gt;It’s &lt;strong&gt;discipline in constraints&lt;/strong&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The shift
&lt;/h2&gt;

&lt;p&gt;You stop seeing:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“random shapes on a poster”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And start seeing:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“a system generating compositions within a bounded design language”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That’s a very different mindset.&lt;/p&gt;

&lt;p&gt;Because now you’re not designing outcomes.&lt;/p&gt;

&lt;p&gt;You’re designing &lt;strong&gt;rules that produce outcomes&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmn9s2h84hjog71g6uyfo.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmn9s2h84hjog71g6uyfo.png" alt=" " width="800" height="461"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  If you want to explore this properly
&lt;/h2&gt;

&lt;p&gt;Don’t just build it once.&lt;/p&gt;

&lt;p&gt;Tweak the constraints.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;change grid density&lt;/li&gt;
&lt;li&gt;limit color combinations&lt;/li&gt;
&lt;li&gt;adjust size distribution&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Watch how outputs evolve.&lt;/p&gt;

&lt;p&gt;That’s where the real learning is.&lt;/p&gt;

&lt;p&gt;Because this challenge looks like a UI generator.&lt;/p&gt;

&lt;p&gt;But it’s actually about something deeper:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;how structure creates beauty… even when randomness is involved&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;👉Try this exact challenge here: &lt;a href="https://vibecodearena.ai/share/efdbbe8e-2b33-4e31-a15a-569ae1326b72" rel="noopener noreferrer"&gt;https://vibecodearena.ai/share/efdbbe8e-2b33-4e31-a15a-569ae1326b72&lt;/a&gt;&lt;/p&gt;

</description>
      <category>hackerearth</category>
      <category>vibecodearena</category>
      <category>ai</category>
      <category>llm</category>
    </item>
    <item>
      <title>I built Geometric Breathing &amp; Meditation app on VCA</title>
      <dc:creator>YASHWANTH REDDY K</dc:creator>
      <pubDate>Sat, 25 Apr 2026 14:25:39 +0000</pubDate>
      <link>https://dev.to/yashwanth_reddyk_ad8c405/i-built-geometric-breathing-meditation-app-on-vca-2h73</link>
      <guid>https://dev.to/yashwanth_reddyk_ad8c405/i-built-geometric-breathing-meditation-app-on-vca-2h73</guid>
      <description>&lt;p&gt;The Animation Isn’t Breathing — Your Timing Logic Is&lt;/p&gt;

&lt;p&gt;At a glance, this feels like one of those “calm UI” exercises.&lt;/p&gt;

&lt;p&gt;A soft glowing shape.&lt;br&gt;
Expand… hold… contract.&lt;br&gt;
Maybe a gentle color palette and a faint sound.&lt;/p&gt;

&lt;p&gt;It looks simple enough that most people jump straight into CSS animations.&lt;/p&gt;

&lt;p&gt;And that’s exactly where things go wrong.&lt;/p&gt;

&lt;p&gt;Because the moment you try to &lt;em&gt;sync everything&lt;/em&gt; — motion, sound, counters, presets — you realize:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;This is not an animation problem.&lt;br&gt;
This is a timing system pretending to be one.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;
  
  
  The illusion of “just use CSS animation”
&lt;/h2&gt;

&lt;p&gt;The obvious move:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;@keyframes breathe {
  0%   { transform: scale(1); }
  33%  { transform: scale(1.3); }
  66%  { transform: scale(1.3); }
  100% { transform: scale(1); }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Looks perfect on paper.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;expand (0 → 33%)&lt;/li&gt;
&lt;li&gt;hold (33 → 66%)&lt;/li&gt;
&lt;li&gt;contract (66 → 100%)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Done.&lt;/p&gt;

&lt;p&gt;Until you try to:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;play a sound exactly at inhale&lt;/li&gt;
&lt;li&gt;increment a counter per full cycle&lt;/li&gt;
&lt;li&gt;change speed dynamically&lt;/li&gt;
&lt;li&gt;switch presets mid-cycle&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now your animation is running on one timeline…&lt;/p&gt;

&lt;p&gt;…and your logic is guessing where it is.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpb02516ypuaftps9wneg.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpb02516ypuaftps9wneg.png" alt=" " width="800" height="473"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  This is where most implementations drift
&lt;/h2&gt;

&lt;p&gt;You end up writing code that tries to “sync” with CSS:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;setInterval(() =&amp;gt; {
  playSound();
}, 4000);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It works.&lt;/p&gt;

&lt;p&gt;Until:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;the tab loses focus&lt;/li&gt;
&lt;li&gt;frame timing shifts&lt;/li&gt;
&lt;li&gt;animation delays slightly&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now your sound is out of phase.&lt;/p&gt;

&lt;p&gt;Your counter increments late.&lt;/p&gt;

&lt;p&gt;Your “breathing” feels… mechanical.&lt;/p&gt;

&lt;h2&gt;
  
  
  The shift: stop syncing &lt;em&gt;to&lt;/em&gt; animation
&lt;/h2&gt;

&lt;p&gt;Start driving animation &lt;em&gt;from&lt;/em&gt; time&lt;/p&gt;

&lt;p&gt;Instead of asking:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“What is the animation doing right now?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;You flip it:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“What phase should we be in right now?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;You define time explicitly:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const PHASES = ["in", "hold", "out"];
const DURATION = 4000;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And track real progression:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const elapsed = (Date.now() - startTime) % (DURATION * 3);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now you know exactly:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;which phase you're in&lt;/li&gt;
&lt;li&gt;how far into it you are&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;No guessing.&lt;/p&gt;

&lt;p&gt;No syncing hacks.&lt;/p&gt;

&lt;h2&gt;
  
  
  The geometry isn’t decorative
&lt;/h2&gt;

&lt;p&gt;It’s expressive&lt;/p&gt;

&lt;p&gt;The requirement says:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;6–8 segments forming a shape&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Most implementations just duplicate elements.&lt;/p&gt;

&lt;p&gt;But the interesting part is how they behave &lt;em&gt;together&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;A single petal scaling is boring.&lt;/p&gt;

&lt;p&gt;Multiple petals slightly offset in rotation?&lt;/p&gt;

&lt;p&gt;Now you get something organic.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;.petal {
  transform: rotate(var(--angle)) scale(var(--scale));
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That &lt;code&gt;--angle&lt;/code&gt; isn’t styling.&lt;/p&gt;

&lt;p&gt;It’s structure.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fo02b1cldky4u96njh2u9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fo02b1cldky4u96njh2u9.png" alt=" " width="800" height="366"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The “bloom” effect is not about size
&lt;/h2&gt;

&lt;p&gt;It’s about &lt;strong&gt;stagger&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;If all segments animate identically, the shape feels rigid.&lt;/p&gt;

&lt;p&gt;If each segment has a slight delay or opacity variation…&lt;/p&gt;

&lt;p&gt;It feels alive.&lt;/p&gt;

&lt;h2&gt;
  
  
  CSS variables quietly become your control panel
&lt;/h2&gt;

&lt;p&gt;This is where the system gets interesting.&lt;/p&gt;

&lt;p&gt;Instead of hardcoding values:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;.petal {
  background: teal;
  transition: 4s;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You externalize everything:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;:root {
  --duration: 4s;
  --color: #4fd1c5;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now your entire animation becomes configurable.&lt;/p&gt;

&lt;p&gt;And JavaScript doesn’t “change styles”.&lt;/p&gt;

&lt;p&gt;It changes &lt;strong&gt;parameters&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Presets stop being themes
&lt;/h2&gt;

&lt;p&gt;They become system reconfigurations&lt;/p&gt;

&lt;p&gt;Switching to “Fire” isn’t just color.&lt;/p&gt;

&lt;p&gt;It’s:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;faster duration&lt;/li&gt;
&lt;li&gt;sharper easing&lt;/li&gt;
&lt;li&gt;higher contrast
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;document.documentElement.style.setProperty("--duration", "2s");
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That one line reshapes the entire experience.&lt;/p&gt;

&lt;h2&gt;
  
  
  The sound exposes your timing bugs instantly
&lt;/h2&gt;

&lt;p&gt;Visual drift is subtle.&lt;/p&gt;

&lt;p&gt;Audio drift is obvious.&lt;/p&gt;

&lt;p&gt;If your “ding” doesn’t land exactly at:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;inhale start&lt;/li&gt;
&lt;li&gt;exhale start&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The whole system feels off.&lt;/p&gt;

&lt;p&gt;Which is why this matters:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;if (phaseChanged) {
  playTone();
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You’re not triggering sound on intervals.&lt;/p&gt;

&lt;p&gt;You’re triggering it on &lt;strong&gt;state transitions&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;That’s a different mindset.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F76lfv1ox3iq11educ20k.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F76lfv1ox3iq11educ20k.png" alt=" " width="800" height="363"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The breath counter is deceptively strict
&lt;/h2&gt;

&lt;p&gt;It doesn’t count:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;expansions&lt;/li&gt;
&lt;li&gt;contractions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It counts &lt;strong&gt;full cycles&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Which means:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;if (phase === "in" &amp;amp;&amp;amp; previousPhase === "out") {
  cycles++;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Tiny detail.&lt;/p&gt;

&lt;p&gt;But if you get this wrong…&lt;/p&gt;

&lt;p&gt;Your app feels inaccurate.&lt;/p&gt;

&lt;p&gt;And in a meditation context, that matters more than visuals.&lt;/p&gt;

&lt;h2&gt;
  
  
  What shows up in Vibe Code Arena
&lt;/h2&gt;

&lt;p&gt;This challenge separates two kinds of thinking.&lt;/p&gt;

&lt;p&gt;One model builds an animation:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;smooth CSS&lt;/li&gt;
&lt;li&gt;decent visuals&lt;/li&gt;
&lt;li&gt;loosely synced JS&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It looks calming.&lt;/p&gt;

&lt;p&gt;But feels slightly disconnected.&lt;/p&gt;

&lt;p&gt;Another model builds a timing system:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;explicit phase tracking&lt;/li&gt;
&lt;li&gt;CSS driven by variables&lt;/li&gt;
&lt;li&gt;JS controlling truth&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now everything aligns:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;motion&lt;/li&gt;
&lt;li&gt;sound&lt;/li&gt;
&lt;li&gt;counting&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And the app feels… intentional.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fov86w91dx888ntdv4ft7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fov86w91dx888ntdv4ft7.png" alt=" " width="800" height="369"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The human version usually does less
&lt;/h2&gt;

&lt;p&gt;But anchors everything in time&lt;/p&gt;

&lt;p&gt;Not more animations.&lt;/p&gt;

&lt;p&gt;Not more effects.&lt;/p&gt;

&lt;p&gt;Just one decision:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Time is the source of truth&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Everything else follows.&lt;/p&gt;

&lt;h2&gt;
  
  
  The part you don’t expect
&lt;/h2&gt;

&lt;p&gt;After building this, you stop seeing:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“a breathing animation”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And start seeing:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“a synchronized system of phases, driven by time, expressed through visuals”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Which is the same pattern behind:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;audio engines&lt;/li&gt;
&lt;li&gt;game loops&lt;/li&gt;
&lt;li&gt;real-time dashboards&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Try this before you move on
&lt;/h2&gt;

&lt;p&gt;Don’t just make it smooth.&lt;/p&gt;

&lt;p&gt;Make it &lt;em&gt;consistent&lt;/em&gt;.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Switch presets mid-cycle&lt;/li&gt;
&lt;li&gt;Tab out and come back&lt;/li&gt;
&lt;li&gt;Let it run for minutes&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Does it stay aligned?&lt;/p&gt;

&lt;p&gt;Or does it drift?&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3bpx4yzlvuohc2si75az.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3bpx4yzlvuohc2si75az.png" alt=" " width="800" height="473"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you want to explore how different approaches handle that tension between animation and timing, this is the exact challenge:&lt;/p&gt;

&lt;p&gt;👉 &lt;a href="https://vibecodearena.ai/share/dabe3e01-ecec-4241-9337-7894057f1d19" rel="noopener noreferrer"&gt;https://vibecodearena.ai/share/dabe3e01-ecec-4241-9337-7894057f1d19&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Play with it.&lt;/p&gt;

&lt;p&gt;But more importantly — observe when it stops feeling natural.&lt;/p&gt;

&lt;p&gt;That’s where the real problem is hiding.&lt;/p&gt;

</description>
      <category>vibecodearena</category>
      <category>hackerearth</category>
      <category>llm</category>
      <category>multimodelduel</category>
    </item>
    <item>
      <title>I built a Cyber-Cipher Text Decoder on Vibe Code Arena</title>
      <dc:creator>YASHWANTH REDDY K</dc:creator>
      <pubDate>Fri, 24 Apr 2026 13:41:40 +0000</pubDate>
      <link>https://dev.to/yashwanth_reddyk_ad8c405/i-built-a-cyber-cipher-text-decoder-on-vibe-code-arena-23jl</link>
      <guid>https://dev.to/yashwanth_reddyk_ad8c405/i-built-a-cyber-cipher-text-decoder-on-vibe-code-arena-23jl</guid>
      <description>&lt;p&gt;There’s a version of this app that’s technically correct.&lt;/p&gt;

&lt;p&gt;You type text.&lt;br&gt;
Click a button.&lt;br&gt;
It returns encrypted output.&lt;/p&gt;

&lt;p&gt;Done.&lt;/p&gt;

&lt;p&gt;And yet… it feels completely lifeless.&lt;/p&gt;

&lt;p&gt;Because nothing &lt;em&gt;happened&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;The system skipped the most important part:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;the transition between meaning and noise&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;
  
  
  The part everyone rushes past
&lt;/h2&gt;

&lt;p&gt;Encryption is usually treated like a function.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;function caesar(str, shift) {
  return str.replace(/[a-z]/gi, c =&amp;gt;
    String.fromCharCode(c.charCodeAt(0) + shift)
  );
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Input → output.&lt;/p&gt;

&lt;p&gt;Clean. Fast. Predictable.&lt;/p&gt;

&lt;p&gt;And completely uninteresting.&lt;/p&gt;

&lt;p&gt;Because in a “cyber terminal” fantasy, encryption isn’t a jump.&lt;/p&gt;

&lt;p&gt;It’s a &lt;strong&gt;process you witness&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  The illusion you’re actually building
&lt;/h2&gt;

&lt;p&gt;What you want is not:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“text becomes encrypted”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;It’s:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“text loses meaning… before gaining a new one”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That in-between state — the flicker — is where the entire experience lives.&lt;/p&gt;

&lt;p&gt;Without it, this is just a textarea with math.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fo8o3jxfelrxpgh3cb0e7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fo8o3jxfelrxpgh3cb0e7.png" alt=" " width="800" height="375"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Where most implementations fall apart
&lt;/h2&gt;

&lt;p&gt;They try something like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;el.textContent = encrypt(input);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then maybe wrap it in a timeout.&lt;/p&gt;

&lt;p&gt;Maybe sprinkle some randomness.&lt;/p&gt;

&lt;p&gt;But it still feels fake.&lt;/p&gt;

&lt;p&gt;Because all characters update &lt;em&gt;at once&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;No tension. No progression.&lt;/p&gt;

&lt;h2&gt;
  
  
  The trick is not randomness
&lt;/h2&gt;

&lt;p&gt;It’s &lt;strong&gt;controlled chaos&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Each character needs its own timeline.&lt;/p&gt;

&lt;p&gt;Not just a delay — a lifecycle.&lt;/p&gt;

&lt;p&gt;Something like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;setTimeout(() =&amp;gt; {
  el[i] = randomSymbol();
}, i * 30);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now things start to stagger.&lt;/p&gt;

&lt;p&gt;But it’s still not enough.&lt;/p&gt;

&lt;p&gt;Because flicker isn’t just delay.&lt;/p&gt;

&lt;p&gt;It’s instability.&lt;/p&gt;

&lt;h2&gt;
  
  
  The version that actually feels right
&lt;/h2&gt;

&lt;p&gt;Instead of swapping once, you let each character &lt;em&gt;struggle&lt;/em&gt; before settling.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;function flickerChar(finalChar, duration = 1000) {
  const chars = "@#$%*&amp;amp;!";
  const start = Date.now();

  return new Promise(resolve =&amp;gt; {
    const interval = setInterval(() =&amp;gt; {
      const now = Date.now();

      if (now - start &amp;gt; duration) {
        clearInterval(interval);
        resolve(finalChar);
      } else {
        resolve(chars[Math.floor(Math.random() * chars.length)]);
      }
    }, 50);
  });
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It’s not just animation.&lt;/p&gt;

&lt;p&gt;It’s simulation of instability.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frhbfsbxd793g05umi8ke.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frhbfsbxd793g05umi8ke.png" alt=" " width="800" height="366"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  And now something subtle happens
&lt;/h2&gt;

&lt;p&gt;The encryption function stops being the star.&lt;/p&gt;

&lt;p&gt;The &lt;strong&gt;transition system&lt;/strong&gt; becomes the real feature.&lt;/p&gt;

&lt;p&gt;Because users don’t remember:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;what the output was&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;They remember:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;how it &lt;em&gt;became&lt;/em&gt; the output&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  The UI starts behaving like a terminal
&lt;/h2&gt;

&lt;p&gt;Now the aesthetic matters more than usual.&lt;/p&gt;

&lt;p&gt;Not because it looks cool.&lt;/p&gt;

&lt;p&gt;Because it reinforces the illusion.&lt;/p&gt;

&lt;p&gt;The moment you switch to:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;green-on-black&lt;/li&gt;
&lt;li&gt;glowing text&lt;/li&gt;
&lt;li&gt;scanlines&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You’re no longer building a UI.&lt;/p&gt;

&lt;p&gt;You’re building a &lt;strong&gt;fiction the user agrees to believe&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Even something as simple as:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;body {
  background: black;
  color: #00ff9f;
  text-shadow: 0 0 8px #00ff9f;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Does more than styling.&lt;/p&gt;

&lt;p&gt;It sets expectations.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7bad39h4inph0bhyqjw6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7bad39h4inph0bhyqjw6.png" alt=" " width="800" height="369"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The glitch toggle is where things get interesting
&lt;/h2&gt;

&lt;p&gt;At first, it feels like a gimmick.&lt;/p&gt;

&lt;p&gt;Shake the text. Add some jitter.&lt;/p&gt;

&lt;p&gt;But it reveals something deeper.&lt;/p&gt;

&lt;p&gt;Because now the system has two states:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;stable&lt;/li&gt;
&lt;li&gt;unstable&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And your UI needs to reflect that &lt;em&gt;continuously&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Not just during animation.&lt;/p&gt;

&lt;p&gt;A tiny class toggle:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;document.body.classList.toggle("glitch");
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Ends up changing the entire &lt;em&gt;mood&lt;/em&gt; of the app.&lt;/p&gt;

&lt;h2&gt;
  
  
  Copy-to-clipboard sounds trivial
&lt;/h2&gt;

&lt;p&gt;It isn’t&lt;/p&gt;

&lt;p&gt;Because this is the only moment where:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;the illusion meets reality&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;You’re taking something from the “terminal”…&lt;/p&gt;

&lt;p&gt;And moving it into the real world.&lt;/p&gt;

&lt;p&gt;That’s why even a small feedback like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;navigator.clipboard.writeText(output);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;paired with a toast matters disproportionately.&lt;/p&gt;

&lt;p&gt;Without it, the system feels incomplete.&lt;/p&gt;

&lt;h2&gt;
  
  
  What shows up in Vibe Code Arena
&lt;/h2&gt;

&lt;p&gt;This challenge creates a very specific divide.&lt;/p&gt;

&lt;p&gt;Not in correctness.&lt;/p&gt;

&lt;p&gt;In &lt;em&gt;experience&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;One model will:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;implement encryption correctly&lt;/li&gt;
&lt;li&gt;add some flicker&lt;/li&gt;
&lt;li&gt;style it decently&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It works.&lt;/p&gt;

&lt;p&gt;But feels like effects layered on top of logic.&lt;/p&gt;

&lt;p&gt;Another model leans into the transition itself:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;staggered character timelines&lt;/li&gt;
&lt;li&gt;independent flicker cycles&lt;/li&gt;
&lt;li&gt;UI reacting per-character&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now the system feels alive.&lt;/p&gt;

&lt;p&gt;Not because of complexity.&lt;/p&gt;

&lt;p&gt;Because of &lt;strong&gt;temporal detail&lt;/strong&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The part that’s easy to miss
&lt;/h2&gt;

&lt;p&gt;This isn’t about encryption.&lt;/p&gt;

&lt;p&gt;It’s about &lt;strong&gt;progressive transformation&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The same pattern shows up in:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;loading states&lt;/li&gt;
&lt;li&gt;skeleton screens&lt;/li&gt;
&lt;li&gt;streaming UIs&lt;/li&gt;
&lt;li&gt;code editors&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Anywhere the system reveals itself over time.&lt;/p&gt;

&lt;h2&gt;
  
  
  The shift
&lt;/h2&gt;

&lt;p&gt;After building this, you stop seeing:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“text gets encrypted”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And start seeing:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“state transitions can be &lt;em&gt;felt&lt;/em&gt;, not just observed”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And that changes how you think about UI entirely.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2e9h7yxue3ncasewu7e6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2e9h7yxue3ncasewu7e6.png" alt=" " width="800" height="465"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  If you want to push this further
&lt;/h2&gt;

&lt;p&gt;Try breaking your own implementation.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;What happens with long text?&lt;/li&gt;
&lt;li&gt;Do all characters resolve cleanly?&lt;/li&gt;
&lt;li&gt;Does glitch mode interfere with flicker timing?&lt;/li&gt;
&lt;li&gt;Does the system feel &lt;em&gt;consistent&lt;/em&gt; every time?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That’s where the real challenge is hiding.&lt;/p&gt;

&lt;p&gt;And if you want to see how different approaches handle that tension between logic and illusion, this is the exact arena where it plays out:&lt;/p&gt;

&lt;p&gt;👉 &lt;a href="https://vibecodearena.ai/share/c8238364-3d2a-4bba-b14c-70146bbe0864" rel="noopener noreferrer"&gt;https://vibecodearena.ai/share/c8238364-3d2a-4bba-b14c-70146bbe0864&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Not to “solve” it.&lt;/p&gt;

&lt;p&gt;But to see how far you can push the transformation before it breaks.&lt;/p&gt;

</description>
      <category>vibecodearena</category>
      <category>hackerearth</category>
      <category>ai</category>
      <category>llm</category>
    </item>
    <item>
      <title>AI Duel on Building Retro RPG Quest Journal</title>
      <dc:creator>YASHWANTH REDDY K</dc:creator>
      <pubDate>Thu, 23 Apr 2026 08:33:41 +0000</pubDate>
      <link>https://dev.to/yashwanth_reddyk_ad8c405/ai-duel-on-building-retro-rpg-quest-journal-a52</link>
      <guid>https://dev.to/yashwanth_reddyk_ad8c405/ai-duel-on-building-retro-rpg-quest-journal-a52</guid>
      <description>&lt;p&gt;There’s a version of this challenge that feels complete in minutes.&lt;/p&gt;

&lt;p&gt;You click a quest.&lt;br&gt;
It turns yellow.&lt;br&gt;
Click again → green, strikethrough.&lt;br&gt;
XP bar fills.&lt;br&gt;
“LEVEL UP!” flashes.&lt;/p&gt;

&lt;p&gt;It’s responsive. It’s clean. It &lt;em&gt;works&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;And yet… if you sit with it for a second, something starts to feel off.&lt;/p&gt;

&lt;p&gt;Not visually.&lt;/p&gt;

&lt;p&gt;Structurally.&lt;/p&gt;

&lt;p&gt;The break doesn’t happen when something fails.&lt;/p&gt;

&lt;p&gt;It happens when you ask a slightly annoying question:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“What &lt;em&gt;actually&lt;/em&gt; controls this system?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Because if the honest answer is “the DOM”… you’ve already lost.&lt;/p&gt;
&lt;h2&gt;
  
  
  Where the illusion begins
&lt;/h2&gt;

&lt;p&gt;Most implementations don’t explicitly choose a bad approach.&lt;/p&gt;

&lt;p&gt;They just drift into it.&lt;/p&gt;

&lt;p&gt;A click handler like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;el&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;classList&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;toggle&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;active&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;feels harmless.&lt;/p&gt;

&lt;p&gt;Then you stack another:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;el&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;classList&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;contains&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;active&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nx"&gt;xp&lt;/span&gt; &lt;span class="o"&gt;+=&lt;/span&gt; &lt;span class="mi"&gt;33&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now your logic is reading from the UI.&lt;/p&gt;

&lt;p&gt;And just like that, the direction flips:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;UI → Logic&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Instead of:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;State → UI&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Nothing breaks immediately.&lt;/p&gt;

&lt;p&gt;Which is why this pattern survives longer than it should.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0qhk53lx6ty5py4968qk.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0qhk53lx6ty5py4968qk.png" alt=" " width="800" height="364"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The moment things get weird
&lt;/h2&gt;

&lt;p&gt;Try this mentally:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Click Quest 1 → Completed&lt;/li&gt;
&lt;li&gt;Click Quest 2 → Completed&lt;/li&gt;
&lt;li&gt;Refresh your understanding (not the page)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now ask:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“How much XP do I have?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;If your system needs to &lt;em&gt;inspect the DOM&lt;/em&gt; to answer that…&lt;/p&gt;

&lt;p&gt;It doesn’t know its own state.&lt;/p&gt;

&lt;p&gt;It’s guessing.&lt;/p&gt;

&lt;h2&gt;
  
  
  The version that feels different (and you can’t unsee it)
&lt;/h2&gt;

&lt;p&gt;At some point, you stop touching the DOM entirely.&lt;/p&gt;

&lt;p&gt;Not physically — but conceptually.&lt;/p&gt;

&lt;p&gt;You start from something like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;game&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;quests&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;state&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;locked&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;state&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;locked&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;state&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;locked&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;],&lt;/span&gt;
  &lt;span class="na"&gt;clicks&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Nothing fancy.&lt;/p&gt;

&lt;p&gt;But now there’s a single place where truth exists.&lt;/p&gt;

&lt;p&gt;And that changes everything downstream.&lt;/p&gt;

&lt;p&gt;Clicking a quest is no longer:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“change how this looks”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;It becomes:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;quest&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;state&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;nextState&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;quest&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;state&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;A mutation of &lt;em&gt;meaning&lt;/em&gt;, not appearance.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fleygybuipeff9g97hlu5.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fleygybuipeff9g97hlu5.png" alt=" " width="800" height="365"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  And then something subtle happens
&lt;/h2&gt;

&lt;p&gt;You stop “updating” the XP bar.&lt;/p&gt;

&lt;p&gt;You remove that code entirely.&lt;/p&gt;

&lt;p&gt;Because XP is no longer something you store.&lt;/p&gt;

&lt;p&gt;It becomes something you &lt;strong&gt;derive&lt;/strong&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;completed&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;game&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;quests&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;filter&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;q&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;q&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;state&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;completed&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;xp&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;completed&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="nx"&gt;game&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;quests&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;No syncing.&lt;/p&gt;

&lt;p&gt;No edge cases.&lt;/p&gt;

&lt;p&gt;No “what if we forgot to update it?”&lt;/p&gt;

&lt;p&gt;It just… exists.&lt;/p&gt;

&lt;h2&gt;
  
  
  This is where AI models start to split
&lt;/h2&gt;

&lt;p&gt;On Vibe Code Arena, this challenge creates a really interesting pattern.&lt;/p&gt;

&lt;p&gt;Not in who gets it working.&lt;/p&gt;

&lt;p&gt;Everyone does.&lt;/p&gt;

&lt;p&gt;But in &lt;em&gt;how stable the system feels when you push it&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;One model tends to scatter logic:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;click handler updates class&lt;/li&gt;
&lt;li&gt;another updates XP&lt;/li&gt;
&lt;li&gt;another checks for level-up&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It’s like three mini-systems loosely cooperating.&lt;/p&gt;

&lt;p&gt;And it holds… until you stress it.&lt;/p&gt;

&lt;p&gt;Another model centralizes everything:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;state changes in one place&lt;/li&gt;
&lt;li&gt;rendering happens in one pass&lt;/li&gt;
&lt;li&gt;UI is always regenerated&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Something like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;render&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="c1"&gt;// read state&lt;/span&gt;
  &lt;span class="c1"&gt;// compute derived values&lt;/span&gt;
  &lt;span class="c1"&gt;// output UI&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That function becomes the entire app.&lt;/p&gt;

&lt;p&gt;Not because it’s elegant.&lt;/p&gt;

&lt;p&gt;Because it’s &lt;strong&gt;predictable&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F75ndt8s1vmsqqfyk65t8.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F75ndt8s1vmsqqfyk65t8.png" alt=" " width="800" height="373"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The “LEVEL UP!” moment is not about animation
&lt;/h2&gt;

&lt;p&gt;It’s where your system gets audited.&lt;/p&gt;

&lt;p&gt;Because now you need to answer:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;When exactly does level-up happen?&lt;/li&gt;
&lt;li&gt;What resets?&lt;/li&gt;
&lt;li&gt;What persists?&lt;/li&gt;
&lt;li&gt;What triggers the animation?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If your logic is scattered, you end up with defensive code:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;xp&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nx"&gt;alreadyLeveled&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="c1"&gt;// do something&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If your logic is grounded in state, it’s almost boring:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;xp&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nx"&gt;level&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nf"&gt;resetQuests&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;No guards. No hacks.&lt;/p&gt;

&lt;p&gt;Just consequence.&lt;/p&gt;

&lt;h2&gt;
  
  
  The part that sneaks up on you
&lt;/h2&gt;

&lt;p&gt;At some point, you stop thinking about:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;quests&lt;/li&gt;
&lt;li&gt;XP bars&lt;/li&gt;
&lt;li&gt;retro UI&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And start thinking in transitions.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;locked&lt;/span&gt; &lt;span class="err"&gt;→&lt;/span&gt; &lt;span class="nx"&gt;active&lt;/span&gt; &lt;span class="err"&gt;→&lt;/span&gt; &lt;span class="nx"&gt;completed&lt;/span&gt; &lt;span class="err"&gt;→&lt;/span&gt; &lt;span class="nx"&gt;locked&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That’s not UI logic.&lt;/p&gt;

&lt;p&gt;That’s a &lt;strong&gt;state machine&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;And once you see it that way…&lt;/p&gt;

&lt;p&gt;Everything simplifies.&lt;/p&gt;

&lt;h2&gt;
  
  
  The UI becomes… replaceable
&lt;/h2&gt;

&lt;p&gt;This is the weirdest shift.&lt;/p&gt;

&lt;p&gt;You realize the visual layer doesn’t matter anymore.&lt;/p&gt;

&lt;p&gt;Pixel font? Doesn’t matter.&lt;br&gt;
Green vs yellow? Cosmetic.&lt;br&gt;
Animation timing? Secondary.&lt;/p&gt;

&lt;p&gt;Because the real system is already stable.&lt;/p&gt;

&lt;p&gt;The UI is just a skin.&lt;/p&gt;

&lt;h2&gt;
  
  
  And this is where most people miss the actual challenge
&lt;/h2&gt;

&lt;p&gt;They think they’re building:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“a retro quest tracker”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;They’re actually being asked:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Can you build a system where every visual outcome is inevitable?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That’s a very different problem.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fifc8obwcmi89fcekcki1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fifc8obwcmi89fcekcki1.png" alt=" " width="800" height="451"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  If you want to feel the difference, not just understand it
&lt;/h2&gt;

&lt;p&gt;Open the challenge.&lt;/p&gt;

&lt;p&gt;But don’t rush to finish it.&lt;/p&gt;

&lt;p&gt;Break it a little.&lt;/p&gt;

&lt;p&gt;Add one more quest.&lt;br&gt;
Click things out of order.&lt;br&gt;
Try to reason about your own system.&lt;/p&gt;

&lt;p&gt;That’s where the gaps show up.&lt;/p&gt;

&lt;p&gt;👉 &lt;a href="https://vibecodearena.ai/share/6bf96add-8e8b-45de-ab7f-43a1124e9d12" rel="noopener noreferrer"&gt;https://vibecodearena.ai/share/6bf96add-8e8b-45de-ab7f-43a1124e9d12&lt;/a&gt;&lt;/p&gt;

</description>
      <category>vibecodearena</category>
      <category>hackerearth</category>
      <category>ai</category>
      <category>llm</category>
    </item>
    <item>
      <title>The Pomodoro Timer Isn’t About Time, It’s About Engineering</title>
      <dc:creator>YASHWANTH REDDY K</dc:creator>
      <pubDate>Wed, 22 Apr 2026 11:03:39 +0000</pubDate>
      <link>https://dev.to/yashwanth_reddyk_ad8c405/the-pomodoro-timer-isnt-about-time-its-about-engineering-llm</link>
      <guid>https://dev.to/yashwanth_reddyk_ad8c405/the-pomodoro-timer-isnt-about-time-its-about-engineering-llm</guid>
      <description>&lt;p&gt;At first glance, this looks like a design problem.&lt;/p&gt;

&lt;p&gt;Make it circular. Make it smooth. Add some pastel colors and a calming font.&lt;/p&gt;

&lt;p&gt;Maybe animate an SVG stroke so it “feels” like time is passing.&lt;/p&gt;

&lt;p&gt;That’s where most implementations land.&lt;/p&gt;

&lt;p&gt;And that’s exactly why most Pomodoro timers feel… slightly off.&lt;/p&gt;

&lt;p&gt;Not broken. Just… untrustworthy.&lt;/p&gt;

&lt;p&gt;Because the moment you switch tabs and come back — the illusion collapses.&lt;/p&gt;

&lt;h2&gt;
  
  
  This isn’t a timer UI
&lt;/h2&gt;

&lt;p&gt;It’s a time reconciliation system&lt;/p&gt;

&lt;p&gt;What you’re really building here is not a countdown.&lt;/p&gt;

&lt;p&gt;You’re building a system that answers one question:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“What time is it &lt;em&gt;supposed&lt;/em&gt; to be right now?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Not:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“How many seconds have I counted?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That difference is subtle.&lt;/p&gt;

&lt;p&gt;And it’s where most AI-generated solutions quietly fail.&lt;/p&gt;

&lt;h2&gt;
  
  
  The illusion of &lt;code&gt;setInterval&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;This is the default move:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nf"&gt;setInterval&lt;/span&gt;&lt;span class="p"&gt;(()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nx"&gt;timeLeft&lt;/span&gt;&lt;span class="o"&gt;--&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;},&lt;/span&gt; &lt;span class="mi"&gt;1000&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It looks correct.&lt;/p&gt;

&lt;p&gt;It behaves correctly… as long as the tab is active.&lt;/p&gt;

&lt;p&gt;But browsers don’t respect your timer.&lt;/p&gt;

&lt;p&gt;They throttle it. Pause it. Delay it.&lt;/p&gt;

&lt;p&gt;So your “1 second” becomes:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;1.3 seconds&lt;/li&gt;
&lt;li&gt;2 seconds&lt;/li&gt;
&lt;li&gt;sometimes… nothing at all&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And your UI keeps pretending everything is fine.&lt;/p&gt;

&lt;p&gt;That’s the bug.&lt;/p&gt;

&lt;p&gt;Not visible. Not crashing.&lt;/p&gt;

&lt;p&gt;Just drifting.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhznisu5gqcwqvyqxqnbj.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhznisu5gqcwqvyqxqnbj.png" alt=" "&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Where it gets interesting
&lt;/h2&gt;

&lt;p&gt;A human usually doesn’t try to “fix” &lt;code&gt;setInterval&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;They abandon the idea entirely.&lt;/p&gt;

&lt;p&gt;Instead of counting time…&lt;/p&gt;

&lt;p&gt;They anchor it.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;endTime&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;Date&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nx"&gt;duration&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now everything changes.&lt;/p&gt;

&lt;p&gt;You’re no longer tracking ticks.&lt;/p&gt;

&lt;p&gt;You’re calculating truth.&lt;/p&gt;

&lt;h2&gt;
  
  
  The timer becomes a projection
&lt;/h2&gt;

&lt;p&gt;Every frame, you ask:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;remaining&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;endTime&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="nb"&gt;Date&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That’s it.&lt;/p&gt;

&lt;p&gt;No drift.&lt;/p&gt;

&lt;p&gt;No accumulation error.&lt;/p&gt;

&lt;p&gt;No dependency on browser behavior.&lt;/p&gt;

&lt;p&gt;Just a recalculation.&lt;/p&gt;

&lt;p&gt;And suddenly:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;tab switching doesn’t matter&lt;/li&gt;
&lt;li&gt;lag doesn’t matter&lt;/li&gt;
&lt;li&gt;animation stays honest&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is the moment the system becomes real.&lt;/p&gt;

&lt;h2&gt;
  
  
  The orbit isn’t visual
&lt;/h2&gt;

&lt;p&gt;It’s mathematical&lt;/p&gt;

&lt;p&gt;The circular progress bar looks like a styling challenge.&lt;/p&gt;

&lt;p&gt;It isn’t.&lt;/p&gt;

&lt;p&gt;It’s a mapping problem:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;time → circumference&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That mapping is where most implementations get shaky.&lt;/p&gt;

&lt;p&gt;Because they treat the circle like decoration.&lt;/p&gt;

&lt;p&gt;Instead of a &lt;strong&gt;visual encoding of state&lt;/strong&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  A small line that carries the entire illusion
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;progress&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;remaining&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="nx"&gt;duration&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That ratio drives everything:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;stroke offset&lt;/li&gt;
&lt;li&gt;animation smoothness&lt;/li&gt;
&lt;li&gt;perception of time&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If this value is wrong — even slightly — the user &lt;em&gt;feels it&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;Not consciously.&lt;/p&gt;

&lt;p&gt;But enough to break immersion.&lt;/p&gt;

&lt;h2&gt;
  
  
  HTML (nothing fancy, and that’s the point)
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"app"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"orbit-container"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;svg&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"orbit"&lt;/span&gt; &lt;span class="na"&gt;viewBox=&lt;/span&gt;&lt;span class="s"&gt;"0 0 120 120"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="nt"&gt;&amp;lt;circle&lt;/span&gt; &lt;span class="na"&gt;cx=&lt;/span&gt;&lt;span class="s"&gt;"60"&lt;/span&gt; &lt;span class="na"&gt;cy=&lt;/span&gt;&lt;span class="s"&gt;"60"&lt;/span&gt; &lt;span class="na"&gt;r=&lt;/span&gt;&lt;span class="s"&gt;"54"&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"bg"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/circle&amp;gt;&lt;/span&gt;
      &lt;span class="nt"&gt;&amp;lt;circle&lt;/span&gt; &lt;span class="na"&gt;cx=&lt;/span&gt;&lt;span class="s"&gt;"60"&lt;/span&gt; &lt;span class="na"&gt;cy=&lt;/span&gt;&lt;span class="s"&gt;"60"&lt;/span&gt; &lt;span class="na"&gt;r=&lt;/span&gt;&lt;span class="s"&gt;"54"&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"progress"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/circle&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/svg&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"time"&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"time"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;25:00&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;

  &lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"controls"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;button&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"focus"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Focus&lt;span class="nt"&gt;&amp;lt;/button&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;button&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"chill"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Chill&lt;span class="nt"&gt;&amp;lt;/button&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;button&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"start"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Start&lt;span class="nt"&gt;&amp;lt;/button&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;button&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"pause"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Pause&lt;span class="nt"&gt;&amp;lt;/button&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;button&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"reset"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Reset&lt;span class="nt"&gt;&amp;lt;/button&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;

  &lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"message"&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"message hidden"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Time to breathe&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The structure is intentionally quiet.&lt;/p&gt;

&lt;p&gt;Because the behavior is doing the heavy lifting.&lt;/p&gt;

&lt;h2&gt;
  
  
  CSS (this is where most people over-design)
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="nt"&gt;body&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nl"&gt;margin&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;font-family&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;"Inter"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;sans-serif&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;background&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#f4f1ee&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#2a2a2a&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;display&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;flex&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;align-items&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;center&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;justify-content&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;center&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;100vh&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.app&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nl"&gt;text-align&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;center&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.orbit-container&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nl"&gt;position&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;relative&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;200px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;200px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;margin&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;auto&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.orbit&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;rotate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;-90deg&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nt"&gt;circle&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="py"&gt;fill&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;none&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="py"&gt;stroke-width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;8&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.bg&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="py"&gt;stroke&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#e0dcd7&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.progress&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="py"&gt;stroke&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#a3c9a8&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="py"&gt;stroke-linecap&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;round&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="py"&gt;stroke-dasharray&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;339.292&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="py"&gt;stroke-dashoffset&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;transition&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;stroke&lt;/span&gt; &lt;span class="m"&gt;0.3s&lt;/span&gt; &lt;span class="n"&gt;ease&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.time&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nl"&gt;position&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;absolute&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;top&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;50%&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;left&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;50%&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;translate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;-50%&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;-50%&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nl"&gt;font-size&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;28px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;font-weight&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;500&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.controls&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nl"&gt;margin-top&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;20px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;display&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;flex&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="py"&gt;gap&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;10px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;justify-content&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;center&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nt"&gt;button&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;10px&lt;/span&gt; &lt;span class="m"&gt;14px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;border&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;none&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;border-radius&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;20px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;background&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#e8e3dd&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;cursor&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;pointer&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.message&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nl"&gt;margin-top&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;20px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;opacity&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;transition&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;opacity&lt;/span&gt; &lt;span class="m"&gt;0.5s&lt;/span&gt; &lt;span class="n"&gt;ease&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.message.show&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nl"&gt;opacity&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nl"&gt;animation&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;pulse&lt;/span&gt; &lt;span class="m"&gt;2s&lt;/span&gt; &lt;span class="n"&gt;infinite&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;@keyframes&lt;/span&gt; &lt;span class="n"&gt;pulse&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;%&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;opacity&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0.3&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="err"&gt;50&lt;/span&gt;&lt;span class="o"&gt;%&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;opacity&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="err"&gt;100&lt;/span&gt;&lt;span class="o"&gt;%&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;opacity&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0.3&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The mistake AI models often make here is excess.&lt;/p&gt;

&lt;p&gt;Too many gradients. Too much glow.&lt;/p&gt;

&lt;p&gt;But “zen” UI is about restraint.&lt;/p&gt;

&lt;p&gt;The absence of noise.&lt;/p&gt;

&lt;h2&gt;
  
  
  JavaScript (this is where the system lives)
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;FULL_DASH&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mf"&gt;339.292&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;duration&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;25&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;60&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;1000&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;endTime&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;timerRunning&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;timeEl&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;time&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;progressEl&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;querySelector&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;.progress&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;messageEl&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;message&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;format&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;ms&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;total&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;max&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;floor&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;ms&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="mi"&gt;1000&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;m&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;String&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;floor&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;total&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="mi"&gt;60&lt;/span&gt;&lt;span class="p"&gt;)).&lt;/span&gt;&lt;span class="nf"&gt;padStart&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;0&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;s&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;String&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;total&lt;/span&gt; &lt;span class="o"&gt;%&lt;/span&gt; &lt;span class="mi"&gt;60&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;padStart&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;0&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;m&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;:&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;s&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;update&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nx"&gt;timerRunning&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;remaining&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;endTime&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="nb"&gt;Date&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

&lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;remaining&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nx"&gt;timerRunning&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;timeEl&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;textContent&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;00:00&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;progressEl&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;style&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;strokeDashoffset&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;FULL_DASH&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;messageEl&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;classList&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;add&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;show&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="k"&gt;return&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;progress&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;remaining&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="nx"&gt;duration&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="nx"&gt;progressEl&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;style&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;strokeDashoffset&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;FULL_DASH&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="nx"&gt;progress&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nx"&gt;timeEl&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;textContent&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;format&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;remaining&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="nf"&gt;requestAnimationFrame&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;update&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;start&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nx"&gt;onclick&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nx"&gt;endTime&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nx"&gt;endTime&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;Date&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nx"&gt;duration&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;else&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nx"&gt;endTime&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;Date&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;endTime&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="nb"&gt;Date&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nx"&gt;timerRunning&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;messageEl&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;classList&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;remove&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;show&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nf"&gt;update&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;

&lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;pause&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nx"&gt;onclick&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nx"&gt;timerRunning&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;duration&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;endTime&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="nb"&gt;Date&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;

&lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;reset&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nx"&gt;onclick&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nx"&gt;timerRunning&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;endTime&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;duration&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;25&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;60&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;1000&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;timeEl&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;textContent&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;25:00&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;progressEl&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;style&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;strokeDashoffset&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;messageEl&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;classList&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;remove&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;show&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;

&lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;focus&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nx"&gt;onclick&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nx"&gt;duration&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;25&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;60&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;1000&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;endTime&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;timeEl&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;textContent&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;25:00&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;

&lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;chill&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nx"&gt;onclick&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
&lt;span class="nx"&gt;duration&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;5&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;60&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;1000&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;endTime&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;timeEl&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;textContent&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;05:00&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F5vntnb78yd8262jf3wno.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F5vntnb78yd8262jf3wno.png" alt=" "&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  AI vs AI vs Human — where the split happens
&lt;/h2&gt;

&lt;p&gt;This challenge looks harmless.&lt;/p&gt;

&lt;p&gt;But in Vibe Code Arena, it exposes something deeper.&lt;/p&gt;

&lt;h3&gt;
  
  
  Model 1: Animation-first thinking
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Gets the orbit working&lt;/li&gt;
&lt;li&gt;Uses &lt;code&gt;setInterval&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Feels smooth… initially&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Until:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;tab switch breaks timing&lt;/li&gt;
&lt;li&gt;animation desyncs from reality&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It optimizes for &lt;em&gt;appearance&lt;/em&gt;, not truth.&lt;/p&gt;

&lt;h3&gt;
  
  
  Model 2: Over-correcting
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Uses timestamps&lt;/li&gt;
&lt;li&gt;But introduces complex state handling&lt;/li&gt;
&lt;li&gt;Adds unnecessary abstractions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It becomes harder to reason about than the problem itself.&lt;/p&gt;

&lt;h3&gt;
  
  
  The human approach
&lt;/h3&gt;

&lt;p&gt;Usually lands somewhere quieter:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;one source of truth → &lt;code&gt;endTime&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;everything derived from &lt;code&gt;Date.now()&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;animation tied to reality, not ticks&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Not because it’s “clean”&lt;/p&gt;

&lt;p&gt;But because it’s &lt;strong&gt;trustworthy&lt;/strong&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  What most people miss
&lt;/h2&gt;

&lt;p&gt;This isn’t about Pomodoro.&lt;/p&gt;

&lt;p&gt;It’s about &lt;strong&gt;temporal systems&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Anywhere you deal with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;timers&lt;/li&gt;
&lt;li&gt;progress&lt;/li&gt;
&lt;li&gt;countdowns&lt;/li&gt;
&lt;li&gt;animations tied to time&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You face the same choice:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Do you simulate time… or reference it?&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Simulation drifts.&lt;/p&gt;

&lt;p&gt;Reference stays anchored.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fprp5grmqxfuqhva3czyi.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fprp5grmqxfuqhva3czyi.png" alt=" "&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The Reality
&lt;/h2&gt;

&lt;p&gt;After building this, you stop seeing:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“a circular timer UI”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And start seeing:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“a continuously reconciled system between real time and visual state”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And once that clicks…&lt;/p&gt;

&lt;p&gt;You start noticing how many apps quietly get this wrong.&lt;/p&gt;

&lt;p&gt;If you want to see how different models handle this (and where they drift), try this exact challenge in AI duel mode on Vibe Code Arena.&lt;/p&gt;

&lt;p&gt;That’s where “working code” and “reliable systems” stop being the same thing.&lt;/p&gt;

&lt;p&gt;👉 Try it out here: &lt;a href="https://vibecodearena.ai/share/d8d9208b-9adc-4d11-91ab-d893900f4222" rel="noopener noreferrer"&gt;https://vibecodearena.ai/share/d8d9208b-9adc-4d11-91ab-d893900f4222&lt;/a&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>vibecidearena</category>
      <category>hackerearth</category>
      <category>llm</category>
    </item>
    <item>
      <title>Building a Real Event Bus in VibeCodeArena</title>
      <dc:creator>YASHWANTH REDDY K</dc:creator>
      <pubDate>Tue, 21 Apr 2026 16:04:03 +0000</pubDate>
      <link>https://dev.to/yashwanth_reddyk_ad8c405/building-a-real-event-bus-in-vibecodearena-534o</link>
      <guid>https://dev.to/yashwanth_reddyk_ad8c405/building-a-real-event-bus-in-vibecodearena-534o</guid>
      <description>&lt;p&gt;There’s a moment in every growing codebase where things start to feel… tangled.&lt;/p&gt;

&lt;p&gt;A button click updates three different parts of the UI.&lt;br&gt;
A network response triggers state changes across multiple modules.&lt;br&gt;
A login event suddenly needs to notify analytics, UI, cache, and permissions.&lt;/p&gt;

&lt;p&gt;At first, you wire things directly:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;loginButton&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;onclick&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nf"&gt;updateUI&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
  &lt;span class="nf"&gt;trackAnalytics&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
  &lt;span class="nf"&gt;refreshData&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It works.&lt;/p&gt;

&lt;p&gt;Until it doesn’t.&lt;/p&gt;

&lt;p&gt;Because now everything knows about everything.&lt;/p&gt;

&lt;p&gt;And that’s where an event bus quietly becomes one of the most powerful abstractions in your system.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Simple Idea That Hides a Complex System
&lt;/h3&gt;

&lt;p&gt;At its core, an event bus sounds trivial:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;on&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;user.login&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;handler&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;emit&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;user.login&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;data&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You publish an event.&lt;/p&gt;

&lt;p&gt;Subscribers react.&lt;/p&gt;

&lt;p&gt;Loose coupling. Clean architecture. Done.&lt;/p&gt;

&lt;p&gt;Except… that’s just the surface.&lt;/p&gt;

&lt;p&gt;The moment you try to build one that feels &lt;em&gt;production-ready&lt;/em&gt;, the complexity starts creeping in from every direction.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Naive Version (and Why It Breaks)
&lt;/h3&gt;

&lt;p&gt;Most implementations begin like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;events&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{};&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;on&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;handler&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nx"&gt;events&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;])&lt;/span&gt; &lt;span class="nx"&gt;events&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[];&lt;/span&gt;
  &lt;span class="nx"&gt;events&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;].&lt;/span&gt;&lt;span class="nf"&gt;push&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;handler&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;emit&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;data&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;events&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="p"&gt;[]).&lt;/span&gt;&lt;span class="nf"&gt;forEach&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;fn&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nf"&gt;fn&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;data&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This works.&lt;/p&gt;

&lt;p&gt;Until you need:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;To remove a handler&lt;/li&gt;
&lt;li&gt;To handle async logic&lt;/li&gt;
&lt;li&gt;To prevent memory leaks&lt;/li&gt;
&lt;li&gt;To debug what’s happening&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And suddenly, this “simple pub-sub” becomes a system design problem.&lt;/p&gt;

&lt;h3&gt;
  
  
  The First Real Upgrade: Control Over Subscriptions
&lt;/h3&gt;

&lt;p&gt;You quickly realize &lt;code&gt;on&lt;/code&gt; isn’t enough.&lt;/p&gt;

&lt;p&gt;You need &lt;code&gt;off&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;off&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;handler&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nx"&gt;events&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;])&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nx"&gt;events&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;events&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;].&lt;/span&gt;&lt;span class="nf"&gt;filter&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;h&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;h&lt;/span&gt; &lt;span class="o"&gt;!==&lt;/span&gt; &lt;span class="nx"&gt;handler&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And then:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;once&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;user.login&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;handler&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Which means wrapping the handler:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;once&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;handler&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;wrapper&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;data&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nf"&gt;handler&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;data&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="nf"&gt;off&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;wrapper&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="p"&gt;};&lt;/span&gt;
  &lt;span class="nf"&gt;on&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;wrapper&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is the first moment where your event bus starts managing &lt;strong&gt;lifecycle&lt;/strong&gt;, not just execution.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fcjjtiyd613v7iegwa6sh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fcjjtiyd613v7iegwa6sh.png" alt=" " width="800" height="366"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Wildcards: When Events Become Patterns
&lt;/h3&gt;

&lt;p&gt;Now imagine:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;on&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;user.*&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;handler&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You emit:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;emit&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;user.login&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;emit&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;user.logout&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Both should trigger the same listener.&lt;/p&gt;

&lt;p&gt;Now your lookup is no longer direct.&lt;/p&gt;

&lt;p&gt;You’re matching patterns.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;matches&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;pattern&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;event&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;pattern&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;endsWith&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;*&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;event&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;startsWith&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;pattern&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;slice&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;pattern&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="nx"&gt;event&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is where your event system starts behaving more like a &lt;strong&gt;router&lt;/strong&gt; than a map.&lt;/p&gt;

&lt;h3&gt;
  
  
  Namespaces: Structure Matters
&lt;/h3&gt;

&lt;p&gt;Then you introduce:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;auth&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="nx"&gt;login&lt;/span&gt;
&lt;span class="nx"&gt;auth&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="nx"&gt;logout&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now events are not just strings.&lt;/p&gt;

&lt;p&gt;They’re &lt;strong&gt;hierarchies&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;And suddenly, design decisions matter:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Should &lt;code&gt;auth:*&lt;/code&gt; catch both?&lt;/li&gt;
&lt;li&gt;Should &lt;code&gt;*&lt;/code&gt; catch everything?&lt;/li&gt;
&lt;li&gt;Should &lt;code&gt;auth:login.success&lt;/code&gt; match &lt;code&gt;auth:*&lt;/code&gt;?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You’re no longer just dispatching events.&lt;/p&gt;

&lt;p&gt;You’re defining a &lt;strong&gt;language of communication&lt;/strong&gt; inside your app.&lt;/p&gt;

&lt;h3&gt;
  
  
  Priority: Who Gets to Speak First?
&lt;/h3&gt;

&lt;p&gt;When multiple handlers exist:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;on&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;data.update&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;handlerA&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;on&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;data.update&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;handlerB&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Order suddenly matters.&lt;/p&gt;

&lt;p&gt;So you introduce priority:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;on&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;data.update&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;handlerA&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;priority&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;10&lt;/span&gt; &lt;span class="p"&gt;});&lt;/span&gt;
&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;on&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;data.update&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;handlerB&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;priority&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt; &lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And sort:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;handlers&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;sort&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="nx"&gt;a&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;b&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;b&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;priority&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="nx"&gt;a&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;priority&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is subtle, but powerful.&lt;/p&gt;

&lt;p&gt;Because now your system supports &lt;strong&gt;controlled execution flow&lt;/strong&gt; without hard dependencies.&lt;/p&gt;

&lt;h3&gt;
  
  
  Async Handlers: Where Things Get Real
&lt;/h3&gt;

&lt;p&gt;Now consider:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;on&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;user.login&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="k"&gt;async &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;data&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nf"&gt;fetchUserProfile&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;What happens when you emit?&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;emit&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;user.login&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;data&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now your &lt;code&gt;emit&lt;/code&gt; must:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Detect async handlers&lt;/li&gt;
&lt;li&gt;Await them properly&lt;/li&gt;
&lt;li&gt;Handle errors
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;emit&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;data&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;for &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;handler&lt;/span&gt; &lt;span class="k"&gt;of&lt;/span&gt; &lt;span class="nx"&gt;handlers&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;try&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nf"&gt;handler&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;data&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;catch &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;err&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;error&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;err&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is where your event bus stops being synchronous glue…&lt;/p&gt;

&lt;p&gt;…and becomes part of your &lt;strong&gt;async control flow&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F09f07cc2qg311tfmt5s5.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F09f07cc2qg311tfmt5s5.png" alt=" " width="800" height="362"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Middleware: The Hidden Power Layer
&lt;/h3&gt;

&lt;p&gt;Now introduce middleware:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;use&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="nx"&gt;event&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;data&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;next&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Event:&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;event&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nf"&gt;next&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Before any handler runs, middleware intercepts.&lt;/p&gt;

&lt;p&gt;This enables:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Logging&lt;/li&gt;
&lt;li&gt;Validation&lt;/li&gt;
&lt;li&gt;Transformation&lt;/li&gt;
&lt;li&gt;Security checks&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Your emit pipeline becomes:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;middleware&lt;/span&gt; &lt;span class="err"&gt;→&lt;/span&gt; &lt;span class="nx"&gt;handlers&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And now your event system feels like a &lt;strong&gt;mini framework&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Debug Mode: Making the Invisible Visible
&lt;/h3&gt;

&lt;p&gt;Without visibility, debugging events is painful.&lt;/p&gt;

&lt;p&gt;So you add:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;debug&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And log:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;EMIT&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="nx"&gt;user&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;login&lt;/span&gt;
&lt;span class="err"&gt;→&lt;/span&gt; &lt;span class="nf"&gt;handlerA &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="nx"&gt;ms&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="err"&gt;→&lt;/span&gt; &lt;span class="nf"&gt;handlerB &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;5&lt;/span&gt;&lt;span class="nx"&gt;ms&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now you can see:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Execution order&lt;/li&gt;
&lt;li&gt;Performance&lt;/li&gt;
&lt;li&gt;Missing handlers&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This transforms your bus from a black box into an observable system.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Edge Case Nobody Talks About: Unsubscribing During Emit
&lt;/h3&gt;

&lt;p&gt;Consider:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;on&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;test&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;handler&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;off&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;test&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;handler&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If you mutate the handler list during iteration, you risk:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Skipping handlers&lt;/li&gt;
&lt;li&gt;Crashing iteration&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;So you clone:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;handlersCopy&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[...&lt;/span&gt;&lt;span class="nx"&gt;handlers&lt;/span&gt;&lt;span class="p"&gt;];&lt;/span&gt;
&lt;span class="nx"&gt;handlersCopy&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;forEach&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;h&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nf"&gt;h&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is the kind of detail that separates a working system from a reliable one.&lt;/p&gt;

&lt;h3&gt;
  
  
  Re-entrancy: Events Triggering Events
&lt;/h3&gt;

&lt;p&gt;Now imagine:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;on&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;A&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;emit&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;B&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;on&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;B&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;emit&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;A&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You’ve just created an infinite loop.&lt;/p&gt;

&lt;p&gt;Handling this requires:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Guarding against recursion&lt;/li&gt;
&lt;li&gt;Tracking active events&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is where your event bus starts dealing with &lt;strong&gt;system safety&lt;/strong&gt;, not just features.&lt;/p&gt;

&lt;h3&gt;
  
  
  Memory Leaks: The Silent Failure
&lt;/h3&gt;

&lt;p&gt;Every &lt;code&gt;on()&lt;/code&gt; adds a reference.&lt;/p&gt;

&lt;p&gt;If you don’t clean up:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Detached components still receive events&lt;/li&gt;
&lt;li&gt;Memory grows silently&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;A robust bus ensures:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Proper &lt;code&gt;off()&lt;/code&gt; usage&lt;/li&gt;
&lt;li&gt;Weak references (if possible)&lt;/li&gt;
&lt;li&gt;Cleanup patterns&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Because leaks don’t show immediately.&lt;/p&gt;

&lt;p&gt;They show in production.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0lnmg066akatiqse7obu.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0lnmg066akatiqse7obu.png" alt=" " width="800" height="380"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  The UI: Where It All Comes Together
&lt;/h3&gt;

&lt;p&gt;Once you visualize:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Active listeners&lt;/li&gt;
&lt;li&gt;Event logs&lt;/li&gt;
&lt;li&gt;Execution order&lt;/li&gt;
&lt;li&gt;Performance timing&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The system becomes tangible.&lt;/p&gt;

&lt;p&gt;You can:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Emit custom events&lt;/li&gt;
&lt;li&gt;Watch handlers fire&lt;/li&gt;
&lt;li&gt;Measure execution time&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And suddenly, this isn’t just infrastructure.&lt;/p&gt;

&lt;p&gt;It’s something you can &lt;em&gt;interact with&lt;/em&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Replay: Time Travel for Events
&lt;/h3&gt;

&lt;p&gt;One of the most interesting features is replay:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;bus&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;replayLast&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;10&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now your system remembers history.&lt;/p&gt;

&lt;p&gt;This enables:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Debugging&lt;/li&gt;
&lt;li&gt;State reconstruction&lt;/li&gt;
&lt;li&gt;Event sourcing patterns&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You’ve moved from real-time system…&lt;/p&gt;

&lt;p&gt;to &lt;strong&gt;time-aware system&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  What You Actually Built
&lt;/h3&gt;

&lt;p&gt;By the end of this challenge, you didn’t just build a pub-sub utility.&lt;/p&gt;

&lt;p&gt;You built:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A pattern-matching event router&lt;/li&gt;
&lt;li&gt;A prioritized execution engine&lt;/li&gt;
&lt;li&gt;An async-safe dispatcher&lt;/li&gt;
&lt;li&gt;A middleware pipeline&lt;/li&gt;
&lt;li&gt;A debugging and observability layer&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That’s not a helper function.&lt;/p&gt;

&lt;p&gt;That’s infrastructure.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Shift in Thinking
&lt;/h3&gt;

&lt;p&gt;After building this, you stop wiring components directly.&lt;/p&gt;

&lt;p&gt;You start thinking:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;“What event should this emit?”&lt;/li&gt;
&lt;li&gt;“Who should listen?”&lt;/li&gt;
&lt;li&gt;“What’s the contract?”&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You design flows, not connections.&lt;/p&gt;

&lt;p&gt;And your system becomes:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;More modular&lt;/li&gt;
&lt;li&gt;More scalable&lt;/li&gt;
&lt;li&gt;Easier to evolve&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7i7g95ma7p47soxm7f7r.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7i7g95ma7p47soxm7f7r.png" alt=" " width="800" height="451"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Final Thought
&lt;/h3&gt;

&lt;p&gt;Most developers use event systems without thinking about them.&lt;/p&gt;

&lt;p&gt;But the moment you build one yourself, you realize:&lt;/p&gt;

&lt;p&gt;The real challenge isn’t sending messages.&lt;/p&gt;

&lt;p&gt;It’s managing &lt;strong&gt;how, when, and in what order they flow through your system&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;And once you understand that,&lt;/p&gt;

&lt;p&gt;you don’t just write features anymore&lt;/p&gt;

&lt;p&gt;you design &lt;strong&gt;communication architectures&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;👉 Try it out here: &lt;a href="https://vibecodearena.ai/share/1be49732-f7cb-49b3-976f-b9f56b8a0f03" rel="noopener noreferrer"&gt;https://vibecodearena.ai/share/1be49732-f7cb-49b3-976f-b9f56b8a0f03&lt;/a&gt;&lt;/p&gt;

</description>
      <category>llm</category>
      <category>hackerearth</category>
      <category>vibecodearena</category>
      <category>softwaredevelopment</category>
    </item>
    <item>
      <title>Building a Dependency Resolver ft. VibeCodeArena</title>
      <dc:creator>YASHWANTH REDDY K</dc:creator>
      <pubDate>Mon, 20 Apr 2026 17:40:21 +0000</pubDate>
      <link>https://dev.to/yashwanth_reddyk_ad8c405/building-a-dependency-resolver-ft-vibecodearena-10ea</link>
      <guid>https://dev.to/yashwanth_reddyk_ad8c405/building-a-dependency-resolver-ft-vibecodearena-10ea</guid>
      <description>&lt;p&gt;There’s a moment every developer has had, even if they don’t say it out loud.&lt;/p&gt;

&lt;p&gt;You run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm &lt;span class="nb"&gt;install&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Thousands of packages get installed. A lockfile appears. Everything just… works.&lt;/p&gt;

&lt;p&gt;And you move on.&lt;/p&gt;

&lt;p&gt;But if you stop for a second and ask &lt;em&gt;what actually just happened&lt;/em&gt;, things get uncomfortable fast.&lt;/p&gt;

&lt;p&gt;How did it decide which version of a package to install?&lt;br&gt;
What happens when two dependencies want different versions of the same thing?&lt;br&gt;
Why do circular dependencies sometimes crash everything?&lt;/p&gt;

&lt;p&gt;This challenge forces you to answer those questions the hard way.&lt;/p&gt;

&lt;p&gt;By building your own &lt;strong&gt;mini dependency resolver&lt;/strong&gt;.&lt;/p&gt;
&lt;h3&gt;
  
  
  It Starts Simple — Until It Really Doesn’t
&lt;/h3&gt;

&lt;p&gt;At the beginning, it feels manageable.&lt;/p&gt;

&lt;p&gt;You define a few packages:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nf"&gt;addPackage&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;react&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;18.2.0&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;scheduler@^0.23.0&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]);&lt;/span&gt;
&lt;span class="nf"&gt;addPackage&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;scheduler&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;0.23.0&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;[]);&lt;/span&gt;
&lt;span class="nf"&gt;addPackage&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;lodash&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;4.17.21&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;[]);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then you say:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nf"&gt;resolve&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;react@18.2.0&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And expect something like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;react@18.2.0
└── scheduler@0.23.0
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;So far, so good.&lt;/p&gt;

&lt;p&gt;But that’s not dependency resolution.&lt;/p&gt;

&lt;p&gt;That’s just following pointers.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fm8b0vsaroc6brbvog7f1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fm8b0vsaroc6brbvog7f1.png" alt=" " width="800" height="365"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  The First Real Problem: Versions Are Not Strings
&lt;/h3&gt;

&lt;p&gt;The moment you introduce semantic versioning, everything changes.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;^1.2.3&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;
&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;~1.2.3&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;
&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;1.2.3&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;These are not just versions.&lt;/p&gt;

&lt;p&gt;They are &lt;strong&gt;constraints&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;And your resolver has to &lt;em&gt;interpret&lt;/em&gt; them.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why &lt;code&gt;^&lt;/code&gt; and &lt;code&gt;~&lt;/code&gt; Are Trickier Than They Look
&lt;/h3&gt;

&lt;p&gt;Take:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="o"&gt;^&lt;/span&gt;&lt;span class="mf"&gt;1.2&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="mi"&gt;3&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This means:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="o"&gt;&amp;gt;=&lt;/span&gt; &lt;span class="mf"&gt;1.2&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="mi"&gt;3&lt;/span&gt; &lt;span class="nx"&gt;AND&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="mf"&gt;2.0&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;But:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="o"&gt;~&lt;/span&gt;&lt;span class="mf"&gt;1.2&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="mi"&gt;3&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Means:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="o"&gt;&amp;gt;=&lt;/span&gt; &lt;span class="mf"&gt;1.2&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="mi"&gt;3&lt;/span&gt; &lt;span class="nx"&gt;AND&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="mf"&gt;1.3&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;So now your system needs to:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Parse version strings into structured data&lt;/li&gt;
&lt;li&gt;Compare versions numerically&lt;/li&gt;
&lt;li&gt;Filter all available versions&lt;/li&gt;
&lt;li&gt;Pick the highest compatible one&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Something like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;isCompatible&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;version&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;range&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="c1"&gt;// parse major, minor, patch&lt;/span&gt;
  &lt;span class="c1"&gt;// apply rules for ^ or ~&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is the first moment where your “simple system” becomes an &lt;strong&gt;algorithmic problem&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Registry Isn’t a List — It’s a Time Machine
&lt;/h3&gt;

&lt;p&gt;You don’t just store one version per package.&lt;/p&gt;

&lt;p&gt;You store many:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;registry&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;lodash&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;4.17.19&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;4.17.20&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;4.17.21&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;
  &lt;span class="na"&gt;axios&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;1.5.0&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;1.6.0&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;So when someone asks for:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;axios&lt;/span&gt;&lt;span class="p"&gt;@&lt;/span&gt;&lt;span class="o"&gt;^&lt;/span&gt;&lt;span class="mf"&gt;1.5&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You don’t return &lt;code&gt;"1.5.0"&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;You return:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;1.6.0&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Because it’s the &lt;strong&gt;highest compatible version&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;This is where most naive implementations fail.&lt;/p&gt;

&lt;p&gt;They match.&lt;/p&gt;

&lt;p&gt;They don’t optimize.&lt;/p&gt;

&lt;h3&gt;
  
  
  Dependency Resolution Is Actually Graph Traversal
&lt;/h3&gt;

&lt;p&gt;Once you move beyond one level, the structure reveals itself:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;A
├── B
│   └── D
└── C
    └── D
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is not a tree.&lt;/p&gt;

&lt;p&gt;This is a &lt;strong&gt;graph&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;And resolving dependencies is not recursion.&lt;/p&gt;

&lt;p&gt;It’s &lt;strong&gt;graph traversal with constraints&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Hidden Complexity: Conflicting Requirements
&lt;/h3&gt;

&lt;p&gt;Now consider:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;A&lt;/span&gt; &lt;span class="err"&gt;→&lt;/span&gt; &lt;span class="nx"&gt;B&lt;/span&gt;&lt;span class="p"&gt;@&lt;/span&gt;&lt;span class="o"&gt;^&lt;/span&gt;&lt;span class="mf"&gt;1.0&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;
&lt;span class="nx"&gt;C&lt;/span&gt; &lt;span class="err"&gt;→&lt;/span&gt; &lt;span class="nx"&gt;B&lt;/span&gt;&lt;span class="p"&gt;@&lt;/span&gt;&lt;span class="o"&gt;^&lt;/span&gt;&lt;span class="mf"&gt;2.0&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You try to resolve:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;root&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;A&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;C&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;What do you do?&lt;/p&gt;

&lt;p&gt;There is no version of &lt;code&gt;B&lt;/code&gt; that satisfies both.&lt;/p&gt;

&lt;p&gt;This is not a bug.&lt;/p&gt;

&lt;p&gt;This is a &lt;strong&gt;conflict&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;And your resolver needs to detect it and explain it.&lt;/p&gt;

&lt;p&gt;Something like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Version conflict:
- A requires B@^1.0.0
- C requires B@^2.0.0
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is where your system stops being a tool…&lt;/p&gt;

&lt;p&gt;…and starts behaving like a real package manager.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7rg9f9m425sj6ygtw9au.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7rg9f9m425sj6ygtw9au.png" alt=" " width="800" height="369"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Cycle Detection: The Silent Killer
&lt;/h3&gt;

&lt;p&gt;Then comes the nightmare scenario:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;A → B → C → A
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If you naively recurse, your program never stops.&lt;/p&gt;

&lt;p&gt;So you introduce something like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;visiting&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;Set&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;resolve&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;pkg&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;visiting&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;has&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;pkg&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;throw&lt;/span&gt; &lt;span class="nc"&gt;Error&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Cycle detected&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="nx"&gt;visiting&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;add&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;pkg&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="p"&gt;...&lt;/span&gt;
  &lt;span class="nx"&gt;visiting&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="k"&gt;delete&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;pkg&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;But detecting a cycle is not enough.&lt;/p&gt;

&lt;p&gt;You need to &lt;strong&gt;explain it&lt;/strong&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Cycle detected:
A → B → C → A
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Because debugging dependency graphs without visibility is a nightmare.&lt;/p&gt;

&lt;h3&gt;
  
  
  Topological Sorting: The “Install Order” Problem
&lt;/h3&gt;

&lt;p&gt;Once everything is resolved, you still have one more step.&lt;/p&gt;

&lt;p&gt;Installation order.&lt;/p&gt;

&lt;p&gt;You can’t install a package before its dependencies.&lt;/p&gt;

&lt;p&gt;So you compute something like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;D → B → C → A
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is a &lt;strong&gt;topological sort&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;And it’s one of those concepts that feels academic…&lt;/p&gt;

&lt;p&gt;until you realize it’s powering every build system you’ve ever used.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fbx5qkp1w6n0k701q9jkq.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fbx5qkp1w6n0k701q9jkq.png" alt=" " width="800" height="378"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  The Resolver Is Not One Function — It’s a System
&lt;/h3&gt;

&lt;p&gt;At this point, your architecture starts to matter.&lt;/p&gt;

&lt;p&gt;You naturally separate concerns:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Registry Layer&lt;/strong&gt; → stores packages and versions&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Version Engine&lt;/strong&gt; → parses and compares semver&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Resolver&lt;/strong&gt; → builds the dependency graph&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Validator&lt;/strong&gt; → detects conflicts and cycles&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;UI Layer&lt;/strong&gt; → displays results&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Because trying to do this in one file?&lt;/p&gt;

&lt;p&gt;That’s how bugs multiply.&lt;/p&gt;

&lt;h3&gt;
  
  
  The UI Changes How You Think About the Problem
&lt;/h3&gt;

&lt;p&gt;Once you visualize the tree:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;react@18.2.0
├── scheduler@0.23.0
└── something-else@1.1.0
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You start noticing things you didn’t before:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Duplicate dependencies&lt;/li&gt;
&lt;li&gt;Deep nesting&lt;/li&gt;
&lt;li&gt;Unexpected versions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And when you add a “Visualize Tree” button, suddenly your resolver becomes explainable.&lt;/p&gt;

&lt;p&gt;Which is what real tools struggle with.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Lockfile: Freezing Time
&lt;/h3&gt;

&lt;p&gt;One of the most underrated features is the lockfile.&lt;/p&gt;

&lt;p&gt;After resolving:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;react&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;18.2.0&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nx"&gt;scheduler&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;0.23.0&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You save it.&lt;/p&gt;

&lt;p&gt;Because next time, you don’t want “latest compatible”.&lt;/p&gt;

&lt;p&gt;You want &lt;strong&gt;exactly this&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;This is the difference between:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Reproducible builds&lt;/li&gt;
&lt;li&gt;And chaos&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Where Most Implementations Break
&lt;/h3&gt;

&lt;p&gt;There’s a pattern you start noticing.&lt;/p&gt;

&lt;p&gt;A lot of systems “work” for simple cases.&lt;/p&gt;

&lt;p&gt;But fail when:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Multiple versions exist&lt;/li&gt;
&lt;li&gt;Constraints overlap&lt;/li&gt;
&lt;li&gt;Graph depth increases&lt;/li&gt;
&lt;li&gt;Cycles appear&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Because dependency resolution is not about happy paths.&lt;/p&gt;

&lt;p&gt;It’s about &lt;strong&gt;edge cases interacting with each other&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Subtle Beauty of This Problem
&lt;/h3&gt;

&lt;p&gt;What makes this challenge special is that it quietly combines:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;String parsing&lt;/li&gt;
&lt;li&gt;Graph theory&lt;/li&gt;
&lt;li&gt;Constraint solving&lt;/li&gt;
&lt;li&gt;System design&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And wraps it in something every developer uses daily.&lt;/p&gt;

&lt;p&gt;You’re not learning an abstract algorithm.&lt;/p&gt;

&lt;p&gt;You’re reverse-engineering reality.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Moment Everything Clicks
&lt;/h3&gt;

&lt;p&gt;There’s a point, somewhere in the middle of debugging, where things shift.&lt;/p&gt;

&lt;p&gt;You stop thinking:&lt;/p&gt;

&lt;p&gt;“Why is this not working?”&lt;/p&gt;

&lt;p&gt;And start thinking:&lt;/p&gt;

&lt;p&gt;“What is the system trying to guarantee?”&lt;/p&gt;

&lt;p&gt;And the answer is:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Consistency&lt;/li&gt;
&lt;li&gt;Determinism&lt;/li&gt;
&lt;li&gt;Compatibility&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That’s what real package managers optimize for.&lt;/p&gt;

&lt;p&gt;Not just installation.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fy52jrzpmm5mzti2lqy82.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fy52jrzpmm5mzti2lqy82.png" alt=" " width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Final Thought
&lt;/h3&gt;

&lt;p&gt;Building a dependency resolver doesn’t just teach you how npm works.&lt;/p&gt;

&lt;p&gt;It teaches you something deeper.&lt;/p&gt;

&lt;p&gt;That most “simple tools” we rely on…&lt;/p&gt;

&lt;p&gt;are actually layers of carefully designed systems solving hard problems quietly.&lt;/p&gt;

&lt;p&gt;And once you’ve built even a tiny version of one,&lt;/p&gt;

&lt;p&gt;you don’t take &lt;code&gt;npm install&lt;/code&gt; for granted anymore.&lt;/p&gt;

&lt;p&gt;You understand the chaos it’s preventing.&lt;/p&gt;

&lt;p&gt;👉 Try it out here: &lt;a href="https://vibecodearena.ai/share/1261e358-7da7-4b9d-ada3-ea495b132806" rel="noopener noreferrer"&gt;https://vibecodearena.ai/share/1261e358-7da7-4b9d-ada3-ea495b132806&lt;/a&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>llm</category>
      <category>hackerearth</category>
      <category>vibecodearena</category>
    </item>
    <item>
      <title>The Illusion of Waves: When “Looks Right” Isn’t “Built Right” ft. VibeCodeArena</title>
      <dc:creator>YASHWANTH REDDY K</dc:creator>
      <pubDate>Sun, 05 Apr 2026 12:36:39 +0000</pubDate>
      <link>https://dev.to/yashwanth_reddyk_ad8c405/the-illusion-of-waves-when-looks-right-isnt-built-right-ft-vibecodearena-2pki</link>
      <guid>https://dev.to/yashwanth_reddyk_ad8c405/the-illusion-of-waves-when-looks-right-isnt-built-right-ft-vibecodearena-2pki</guid>
      <description>&lt;p&gt;There’s something fascinating about challenges that feel visual but are actually deeply mathematical underneath. The “Ripple Wave Visualizer” prompt sits exactly in that category. At first glance, it sounds like a UI problem—draw some circles, animate them, make it pretty. But the moment you start thinking about what a ripple actually is, you realize you’re not building a UI anymore. You’re attempting to simulate a physical phenomenon.&lt;/p&gt;

&lt;p&gt;And that’s where things got interesting.&lt;/p&gt;

&lt;p&gt;Two models took on this challenge. Both produced working outputs. Both rendered ripples on a canvas. Both had controls, interactions, and animation loops. But under the surface, they reveal two very different interpretations of the same problem—and more importantly, two different limitations of AI-generated code.&lt;/p&gt;

&lt;p&gt;Let’s unpack this properly.&lt;/p&gt;

&lt;h2&gt;
  
  
  What Was Asked vs What Was Built
&lt;/h2&gt;

&lt;p&gt;The prompt wasn’t vague. It explicitly asked for:&lt;/p&gt;

&lt;p&gt;Ripples behaving like real waves&lt;/p&gt;

&lt;p&gt;Overlapping waves with interference&lt;/p&gt;

&lt;p&gt;Organic motion using sine or ripple physics&lt;/p&gt;

&lt;p&gt;A calming, almost meditative visual experience&lt;/p&gt;

&lt;p&gt;That’s not just animation. That’s simulation.&lt;/p&gt;

&lt;p&gt;Now look at what both models actually built.&lt;/p&gt;

&lt;p&gt;Both implementations reduce the concept of a ripple to this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;radius&lt;/span&gt; &lt;span class="o"&gt;+=&lt;/span&gt; &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;speed&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;alpha&lt;/span&gt; &lt;span class="o"&gt;-=&lt;/span&gt; &lt;span class="nx"&gt;fadeRate&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And then render it using:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;ctx&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;arc&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;x&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;y&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;radius&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;PI&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That’s it.&lt;/p&gt;

&lt;p&gt;No wave equation. No displacement field. No interference. No energy transfer.&lt;/p&gt;

&lt;p&gt;Just expanding circles.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0zbm400d3p0bsk060mbz.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0zbm400d3p0bsk060mbz.jpg" alt=" " width="800" height="430"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Model 1 (GPT-4o): Clean Execution, Shallow Physics
&lt;/h2&gt;

&lt;p&gt;The first model does a respectable job if you judge it purely as a frontend exercise. The structure is clean, the controls are wired correctly, and the animation loop is stable.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;ripples&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;ripples&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;filter&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;ripple&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;ripple&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;update&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;
&lt;span class="nf"&gt;requestAnimationFrame&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;animate&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;There’s discipline here. The lifecycle is well-managed. The UI responds properly. Even small touches like converting hex color into RGB arrays show attention to detail.&lt;/p&gt;

&lt;p&gt;But then you notice something subtle that changes everything.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;intensity&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;intensity&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It’s defined… and never used.&lt;/p&gt;

&lt;p&gt;That one line tells you a lot. The model understood that “intensity” should exist, but didn’t actually connect it to any meaningful behavior—no amplitude scaling, no wave thickness, no energy propagation.&lt;/p&gt;

&lt;p&gt;It’s a placeholder for an idea it didn’t fully implement.&lt;/p&gt;

&lt;p&gt;The same pattern appears elsewhere. The ripples overlap visually, but they don’t interact. There’s no shared medium, no combined displacement. Each ripple lives in isolation, unaware of others.&lt;/p&gt;

&lt;p&gt;And then there’s the rendering:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;ctx&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;clearRect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;canvas&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;width&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;canvas&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;height&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Every frame wipes the canvas clean. No persistence, no blending, no glow accumulation. The result is visually neat, but sterile. It lacks the richness you expect from something described as “mesmerizing.”&lt;/p&gt;

&lt;p&gt;Even the auto-rain system hints at architectural shortcuts:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nf"&gt;setTimeout&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;autoRainEffect&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;500&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It works, but it’s detached from the main animation loop. There’s no centralized timing system, which means behavior can drift or stack unpredictably.&lt;/p&gt;

&lt;p&gt;So what did Model 1 really build?&lt;/p&gt;

&lt;p&gt;A well-structured animation demo that looks like ripples—but doesn’t behave like them.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fs1kvxj41fprvo9lnsibg.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fs1kvxj41fprvo9lnsibg.jpg" alt=" " width="800" height="470"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Model 2 (GPT-4o-mini): Simpler, But Also More Fragile
&lt;/h2&gt;

&lt;p&gt;If Model 1 feels like a clean frontend project, Model 2 feels like a quick prototype pushed out the door.&lt;/p&gt;

&lt;p&gt;At a glance, it’s similar. Same expanding circles. Same fade-out logic. Same basic idea.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;radius&lt;/span&gt; &lt;span class="o"&gt;+=&lt;/span&gt; &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;speed&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;alpha&lt;/span&gt; &lt;span class="o"&gt;-=&lt;/span&gt; &lt;span class="mf"&gt;0.01&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;But the cracks show much earlier.&lt;/p&gt;

&lt;p&gt;The rendering approach switches from stroke-based circles to filled ones:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;ctx&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;fillStyle&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;`rgba(...)`&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;ctx&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;fill&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This creates a very different visual effect—more like blobs than waves. Instead of elegant expanding rings, you get solid discs fading into each other. It’s heavier, less refined, and loses that “water surface” illusion entirely.&lt;/p&gt;

&lt;p&gt;Then there’s state management. Instead of filtering the array cleanly, it mutates it during iteration:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;ripple&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;alpha&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="nx"&gt;ripples&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;splice&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;index&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is a classic source of bugs. Removing elements while iterating can skip items or cause inconsistent behavior, especially as the system scales.&lt;/p&gt;

&lt;p&gt;The “Auto Rain” feature is where things get particularly telling:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;autoRainToggle&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;checked&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nf"&gt;setInterval&lt;/span&gt;&lt;span class="p"&gt;(()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="p"&gt;...&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt; &lt;span class="mi"&gt;1000&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This runs once at load. Toggling the checkbox later doesn’t actually control anything. The feature exists in UI, but not in behavior.&lt;/p&gt;

&lt;p&gt;Again, we see the same pattern: the idea is present, the implementation is partial.&lt;/p&gt;

&lt;p&gt;Even basic constraints like limiting ripple count:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;ripples&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;maxRipples&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;feel more like safeguards against performance issues than part of a thoughtful system design.&lt;/p&gt;

&lt;p&gt;And just like Model 1, there is zero attempt at real wave physics. No interference. No medium. No propagation logic beyond “increase radius.”&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fkpwdytqrjzj487qanrbf.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fkpwdytqrjzj487qanrbf.jpg" alt=" " width="800" height="448"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The Bigger Problem: Both Models Miss the Core Concept
&lt;/h2&gt;

&lt;p&gt;Here’s the uncomfortable truth.&lt;/p&gt;

&lt;p&gt;Neither model actually solved the problem.&lt;/p&gt;

&lt;p&gt;They both solved a simplified version of it.&lt;/p&gt;

&lt;p&gt;What was required:&lt;/p&gt;

&lt;p&gt;A system where waves propagate through a medium, interact with each other, and create emergent patterns.&lt;/p&gt;

&lt;p&gt;What was built:&lt;/p&gt;

&lt;p&gt;Independent objects that draw circles and fade out.&lt;/p&gt;

&lt;p&gt;That’s not a small gap. That’s the difference between simulation and animation.&lt;/p&gt;

&lt;p&gt;A real ripple system would look more like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;height&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;x&lt;/span&gt;&lt;span class="p"&gt;][&lt;/span&gt;&lt;span class="nx"&gt;y&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;wave1&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;x&lt;/span&gt;&lt;span class="p"&gt;][&lt;/span&gt;&lt;span class="nx"&gt;y&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nx"&gt;wave2&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;x&lt;/span&gt;&lt;span class="p"&gt;][&lt;/span&gt;&lt;span class="nx"&gt;y&lt;/span&gt;&lt;span class="p"&gt;];&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You’d have a grid. Each point would store displacement. Waves would travel through that grid, interfere constructively and destructively, and decay over time.&lt;/p&gt;

&lt;p&gt;None of that exists here.&lt;/p&gt;

&lt;p&gt;And that’s the key insight.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why This Happens
&lt;/h2&gt;

&lt;p&gt;AI models are incredibly good at pattern matching. They’ve seen ripple effects implemented as expanding circles thousands of times across tutorials, demos, and code snippets.&lt;/p&gt;

&lt;p&gt;So when asked to build a ripple system, they default to the most common visual approximation.&lt;/p&gt;

&lt;p&gt;It looks right.&lt;/p&gt;

&lt;p&gt;It behaves wrong.&lt;/p&gt;

&lt;p&gt;And unless you’re specifically looking for physical accuracy, you might not even notice.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fkwu5t05odik5x5q0w7tl.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fkwu5t05odik5x5q0w7tl.jpg" alt=" " width="800" height="700"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  So… Which Model Is Better?
&lt;/h2&gt;

&lt;p&gt;If you’re choosing purely on engineering quality, Model 1 is the clear winner.&lt;/p&gt;

&lt;p&gt;It has:&lt;/p&gt;

&lt;p&gt;Cleaner state management&lt;/p&gt;

&lt;p&gt;Better structured animation loop&lt;/p&gt;

&lt;p&gt;More consistent UI integration&lt;/p&gt;

&lt;p&gt;Fewer logical bugs&lt;/p&gt;

&lt;p&gt;Model 2, while functional, feels more fragile and less polished.&lt;/p&gt;

&lt;p&gt;But here’s the twist.&lt;/p&gt;

&lt;p&gt;Neither model actually delivers what the prompt truly asks for.&lt;/p&gt;

&lt;p&gt;So the real takeaway isn’t just “Model 1 wins.”&lt;/p&gt;

&lt;p&gt;It’s this:&lt;/p&gt;

&lt;p&gt;Both models demonstrate how easy it is to mistake visual correctness for technical correctness.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpnuwl3otmjgjbuqo4q36.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpnuwl3otmjgjbuqo4q36.jpg" alt=" " width="800" height="490"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The Real Lesson
&lt;/h2&gt;

&lt;p&gt;This challenge isn’t about canvas, sliders, or animations.&lt;/p&gt;

&lt;p&gt;It’s about understanding what you’re building.&lt;/p&gt;

&lt;p&gt;If you think in terms of shapes, you’ll draw circles.&lt;br&gt;
If you think in terms of systems, you’ll simulate waves.&lt;/p&gt;

&lt;p&gt;That’s the difference.&lt;/p&gt;

&lt;p&gt;And it’s exactly the kind of gap that platforms like Vibe Code Arena expose really well. You don’t just see outputs—you see how different models think about problems.&lt;/p&gt;

&lt;p&gt;Sometimes they’re right. Sometimes they’re convincing. And sometimes, like in this case, they’re just approximating something much deeper.&lt;/p&gt;

&lt;p&gt;If you want to explore this challenge yourself and see how your thinking compares, try it here:&lt;/p&gt;

&lt;p&gt;👉 &lt;a href="https://vibecodearena.ai/share/b2ae08e5-d6a7-43ef-9949-64e2eb031a19" rel="noopener noreferrer"&gt;https://vibecodearena.ai/share/b2ae08e5-d6a7-43ef-9949-64e2eb031a19&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Because once you notice the difference between an animation and a system, you can’t unsee it. ;)&lt;/p&gt;

</description>
      <category>ai</category>
      <category>hackerearth</category>
      <category>vibecodearena</category>
      <category>llm</category>
    </item>
    <item>
      <title>Hard Lessons from the Vibe Code Arena</title>
      <dc:creator>YASHWANTH REDDY K</dc:creator>
      <pubDate>Tue, 31 Mar 2026 17:18:38 +0000</pubDate>
      <link>https://dev.to/yashwanth_reddyk_ad8c405/hard-lessons-from-the-vibe-code-arena-5613</link>
      <guid>https://dev.to/yashwanth_reddyk_ad8c405/hard-lessons-from-the-vibe-code-arena-5613</guid>
      <description>&lt;p&gt;At some point, the challenges stop being about the problem statement.&lt;/p&gt;

&lt;p&gt;You start noticing something else entirely.&lt;/p&gt;

&lt;p&gt;It’s not &lt;em&gt;what&lt;/em&gt; gets built—it’s &lt;em&gt;how differently the same thing gets built&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;That’s where &lt;strong&gt;Vibe Code Arena&lt;/strong&gt; gets interesting. Not because you’re solving problems, but because you’re watching multiple models—and sometimes humans—solve the &lt;em&gt;same problem&lt;/em&gt; with completely different mental models.&lt;/p&gt;

&lt;p&gt;And if you pay attention, you start to see patterns. Not just in correctness, but in architecture, trade-offs, and even subtle bugs that don’t show up until you look closely.&lt;/p&gt;

&lt;h2&gt;
  
  
  When Three “Correct” Solutions Are Not the Same
&lt;/h2&gt;

&lt;p&gt;One of the most misleading things about multi-model duels is the evaluation scores.&lt;/p&gt;

&lt;p&gt;You’ll often see this:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;100%&lt;/li&gt;
&lt;li&gt;100%&lt;/li&gt;
&lt;li&gt;100%&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And you assume—&lt;em&gt;they’re all equally good&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;They’re not.&lt;/p&gt;

&lt;p&gt;Take something like the breathing app challenge. On the surface, every solution animated a circle, showed text like “Inhale…” and “Exhale…”, and had buttons.&lt;/p&gt;

&lt;p&gt;Functionally, all of them passed.&lt;/p&gt;

&lt;p&gt;But under the hood, the differences were massive.&lt;/p&gt;

&lt;p&gt;One solution leaned entirely on CSS animations:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="k"&gt;@keyframes&lt;/span&gt; &lt;span class="n"&gt;breathe&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;%&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;scale&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="err"&gt;50&lt;/span&gt;&lt;span class="o"&gt;%&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;scale&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;1.2&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="err"&gt;100&lt;/span&gt;&lt;span class="o"&gt;%&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;scale&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It looks clean. It works. It even feels smooth.&lt;/p&gt;

&lt;p&gt;But the moment you try to &lt;em&gt;control&lt;/em&gt; it—pause, sync instructions, change durations dynamically—it starts to resist you.&lt;/p&gt;

&lt;p&gt;Another solution went fully programmatic:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;circle&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;style&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;transition&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;`transform &lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;duration&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;s ease`&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;circle&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;style&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;transform&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;`scale(&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;target&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;)`&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now you’re not just animating—you’re &lt;em&gt;controlling state over time&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;Same output. Completely different capabilities.&lt;/p&gt;

&lt;h2&gt;
  
  
  Multi-Model Duels Expose “Thinking Styles”
&lt;/h2&gt;

&lt;p&gt;What stands out after a few challenges is that models don’t just differ in quality—they differ in &lt;em&gt;how they think about problems&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;Some models tend to flatten everything into a linear flow:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;inhale&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nf"&gt;setTimeout&lt;/span&gt;&lt;span class="p"&gt;(()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nf"&gt;hold&lt;/span&gt;&lt;span class="p"&gt;(),&lt;/span&gt; &lt;span class="mi"&gt;4000&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It’s almost like writing a script: do this, then this, then this.&lt;/p&gt;

&lt;p&gt;It works—until you need to interrupt it.&lt;/p&gt;

&lt;p&gt;Other implementations start introducing structure, even if unintentionally:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;phase&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;inhale&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;next&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;phase&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;inhale&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;phase&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;hold&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is where things start resembling systems instead of scripts.&lt;/p&gt;

&lt;p&gt;And once you notice it, you can’t unsee it.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Real Difference Shows Up in Edge Cases
&lt;/h2&gt;

&lt;p&gt;The easiest way to evaluate code isn’t by reading it.&lt;/p&gt;

&lt;p&gt;It’s by &lt;em&gt;breaking it&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;Try hitting “Start” multiple times.&lt;br&gt;
Try switching difficulty mid-game.&lt;br&gt;
Try resetting while an animation is running.&lt;/p&gt;

&lt;p&gt;That’s where things get interesting.&lt;/p&gt;

&lt;p&gt;In one Rock-Paper-Scissors implementation, the “hard mode” logic looked convincing:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;difficulty&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;hard&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;last&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;localStorage&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getItem&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;lastMove&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="c1"&gt;// counter logic&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;But the system never actually tracked frequency—only the last move. So it &lt;em&gt;felt&lt;/em&gt; intelligent, but wasn’t.&lt;/p&gt;

&lt;p&gt;Another version actually tracked history:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;moveHistory&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;push&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;playerChoice&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;moveHistory&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;5&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nx"&gt;moveHistory&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;shift&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then computed the most frequent move and countered it.&lt;/p&gt;

&lt;p&gt;Now you’re not just reacting—you’re modeling behavior over time.&lt;/p&gt;

&lt;p&gt;Same feature. Completely different depth.&lt;/p&gt;

&lt;h2&gt;
  
  
  UI vs System: Where Most Implementations Drift
&lt;/h2&gt;

&lt;p&gt;A pattern that keeps showing up across challenges is this:&lt;/p&gt;

&lt;p&gt;AI is excellent at building &lt;em&gt;interfaces&lt;/em&gt;.&lt;br&gt;
But systems? That’s where things start to wobble.&lt;/p&gt;

&lt;p&gt;You’ll see beautifully structured DOM manipulation:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;counterEl&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;textContent&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;body&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;style&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;backgroundColor&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;green&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Everything updates correctly. It’s responsive. It looks right.&lt;/p&gt;

&lt;p&gt;But then you look at the logic layer—and it’s often tightly coupled to UI updates.&lt;/p&gt;

&lt;p&gt;There’s no separation between:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;state&lt;/li&gt;
&lt;li&gt;logic&lt;/li&gt;
&lt;li&gt;rendering&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And that becomes a problem the moment complexity increases.&lt;/p&gt;

&lt;p&gt;In contrast, stronger implementations start separating concerns—even in small ways:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;determineWinner&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;player&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;computer&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="c1"&gt;// pure logic&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;updateUI&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;result&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="c1"&gt;// rendering&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It’s subtle. But it’s the difference between something that scales and something that breaks.&lt;/p&gt;

&lt;h2&gt;
  
  
  Security and “Silent Failures” in Simple Apps
&lt;/h2&gt;

&lt;p&gt;One thing that doesn’t get talked about enough in these challenges is how fragile even “simple” apps can be.&lt;/p&gt;

&lt;p&gt;Take the password generator.&lt;/p&gt;

&lt;p&gt;At first glance, it looks solid. Random characters, strength meter, copy button.&lt;/p&gt;

&lt;p&gt;But then you look closer.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;password&lt;/span&gt; &lt;span class="o"&gt;+=&lt;/span&gt; &lt;span class="nx"&gt;charset&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;randomIndex&lt;/span&gt;&lt;span class="p"&gt;];&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This uses &lt;code&gt;Math.random()&lt;/code&gt;, which is &lt;em&gt;not&lt;/em&gt; cryptographically secure.&lt;/p&gt;

&lt;p&gt;For a UI demo? Fine.&lt;/p&gt;

&lt;p&gt;For a real product? This is a vulnerability.&lt;/p&gt;

&lt;p&gt;A more secure approach would be:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;array&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;Uint32Array&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nx"&gt;crypto&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getRandomValues&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;array&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That’s the kind of detail most implementations skip.&lt;/p&gt;

&lt;p&gt;And it matters.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Illusion of Smart Features
&lt;/h2&gt;

&lt;p&gt;Another pattern: features that &lt;em&gt;look&lt;/em&gt; advanced but are actually shallow.&lt;/p&gt;

&lt;p&gt;Difficulty modes. Strength meters. Animations.&lt;/p&gt;

&lt;p&gt;They’re often implemented just enough to pass the requirement.&lt;/p&gt;

&lt;p&gt;For example, a strength meter might do this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;12&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="nx"&gt;strength&lt;/span&gt; &lt;span class="o"&gt;+=&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;hasUppercase&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="nx"&gt;strength&lt;/span&gt; &lt;span class="o"&gt;+=&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;But it ignores entropy, repetition, predictable patterns.&lt;/p&gt;

&lt;p&gt;So you end up with a “Very Strong” password that’s actually weak.&lt;/p&gt;

&lt;p&gt;This isn’t a bug—it’s a limitation of how the problem was interpreted.&lt;/p&gt;

&lt;p&gt;And that’s what makes these duels interesting.&lt;/p&gt;

&lt;p&gt;You’re not just evaluating correctness. You’re evaluating &lt;em&gt;depth of understanding&lt;/em&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  What You Start Noticing After Enough Challenges
&lt;/h2&gt;

&lt;p&gt;After going through multiple duels on &lt;strong&gt;Vibe Code Arena&lt;/strong&gt;, a few things become very clear:&lt;/p&gt;

&lt;p&gt;You stop trusting surface-level correctness.&lt;br&gt;
You start looking for control flow.&lt;br&gt;
You care more about &lt;em&gt;what happens over time&lt;/em&gt; than what happens instantly.&lt;/p&gt;

&lt;p&gt;You begin to notice things like:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Are timers centralized or scattered?&lt;/li&gt;
&lt;li&gt;Is state explicit or implied?&lt;/li&gt;
&lt;li&gt;Can this be paused, reset, or extended safely?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These aren’t things you notice on day one.&lt;/p&gt;

&lt;p&gt;But once you do, every piece of code starts telling you more than it used to.&lt;/p&gt;
&lt;h2&gt;
  
  
  The Platform Isn’t Just About Challenges
&lt;/h2&gt;

&lt;p&gt;What makes &lt;strong&gt;Vibe Code Arena&lt;/strong&gt; different is that it doesn’t just show you outputs—it puts them &lt;em&gt;side by side&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;And that changes how you think.&lt;/p&gt;

&lt;p&gt;Because now you’re not asking:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Is this correct?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;You’re asking:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Why did this model choose this approach?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And sometimes the answer is more valuable than the solution itself.&lt;/p&gt;
&lt;h2&gt;
  
  
  A Small Snippet That Says a Lot
&lt;/h2&gt;

&lt;p&gt;Here’s something that looks trivial:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nf"&gt;setTimeout&lt;/span&gt;&lt;span class="p"&gt;(()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nf"&gt;nextPhase&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;span class="p"&gt;},&lt;/span&gt; &lt;span class="nx"&gt;duration&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This one line tells you everything about an implementation.&lt;/p&gt;

&lt;p&gt;Is there a global controller?&lt;br&gt;
Is this being tracked?&lt;br&gt;
Can it be cancelled?&lt;/p&gt;

&lt;p&gt;Or is it just… running?&lt;/p&gt;

&lt;p&gt;That’s the level these challenges operate at once you start paying attention.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where This Actually Leads
&lt;/h2&gt;

&lt;p&gt;At the end of all this, you don’t just get better at writing code.&lt;/p&gt;

&lt;p&gt;You get better at &lt;em&gt;reading intent&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;You start seeing:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;shortcuts&lt;/li&gt;
&lt;li&gt;assumptions&lt;/li&gt;
&lt;li&gt;hidden complexity&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And more importantly, you start understanding that:&lt;/p&gt;

&lt;p&gt;Good code isn’t just about solving the problem.&lt;/p&gt;

&lt;p&gt;It’s about &lt;em&gt;how resilient that solution is when the problem changes&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frzhfr1ijt4y9q4eszlma.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frzhfr1ijt4y9q4eszlma.png" alt=" " width="800" height="412"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Try Looking at Code This Way
&lt;/h2&gt;

&lt;p&gt;If you’ve been building or testing on &lt;strong&gt;Vibe Code Arena&lt;/strong&gt;, try this next time:&lt;/p&gt;

&lt;p&gt;Don’t just run the solution.&lt;/p&gt;

&lt;p&gt;Interrogate it.&lt;/p&gt;

&lt;p&gt;Break it.&lt;br&gt;
Pause it.&lt;br&gt;
Spam the buttons.&lt;br&gt;
Change states mid-flow.&lt;/p&gt;

&lt;p&gt;That’s where the real differences show up.&lt;/p&gt;

&lt;p&gt;And if you want to see exactly what this kind of analysis feels like in practice, try one of the latest challenges here:&lt;/p&gt;

&lt;p&gt;👉 &lt;a href="https://vibecodearena.ai/share/6ddc5143-faa8-4df7-ad8e-8c3c98a71357" rel="noopener noreferrer"&gt;https://vibecodearena.ai/share/6ddc5143-faa8-4df7-ad8e-8c3c98a71357&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;You might start by comparing outputs.&lt;/p&gt;

&lt;p&gt;But if you look closely enough, you’ll end up understanding systems;)&lt;/p&gt;

</description>
      <category>ai</category>
      <category>vibecoding</category>
      <category>vibecodearena</category>
      <category>hackerearth</category>
    </item>
    <item>
      <title>Why This “Simple” Breathing App Quietly Breaks Most Code</title>
      <dc:creator>YASHWANTH REDDY K</dc:creator>
      <pubDate>Sat, 28 Mar 2026 11:47:11 +0000</pubDate>
      <link>https://dev.to/yashwanth_reddyk_ad8c405/why-this-simple-breathing-app-quietly-breaks-most-code-4a4c</link>
      <guid>https://dev.to/yashwanth_reddyk_ad8c405/why-this-simple-breathing-app-quietly-breaks-most-code-4a4c</guid>
      <description>&lt;p&gt;There’s something deceptive about challenges like this one.&lt;/p&gt;

&lt;p&gt;At a glance, it feels almost trivial. A circle expands, contracts, and some text changes in sync—&lt;em&gt;Inhale… Hold… Exhale…&lt;/em&gt;. Add a couple of buttons, maybe a toggle for difficulty or presets, and you’re done. It’s the kind of problem that gives you confidence before you even open your editor.&lt;/p&gt;

&lt;p&gt;But the moment you actually dig into implementations—especially when you compare an AI-generated solution with a human-built one—you start to notice something uncomfortable.&lt;/p&gt;

&lt;p&gt;This isn’t really about animation at all.&lt;/p&gt;

&lt;p&gt;It’s about control over time, state, and behavior in an environment that doesn’t naturally guarantee any of those things.&lt;/p&gt;

&lt;h2&gt;
  
  
  The entire experience is built on a fragile foundation: timing.
&lt;/h2&gt;

&lt;p&gt;Every phase in the breathing cycle carries an expectation. When the UI says “Inhale,” the circle must expand at exactly the same pace. When it says “Hold,” nothing should move—not even subtly. And when “Exhale” begins, the transition needs to feel intentional, not delayed or rushed.&lt;/p&gt;

&lt;p&gt;The problem is that the browser doesn’t care about your intentions.&lt;/p&gt;

&lt;p&gt;JavaScript timers are not perfectly precise. Tabs lose focus. Event loops get blocked. Animations continue running even when logic changes. So the real challenge here is not creating motion—it’s ensuring that motion, text, and logic remain synchronized over time.&lt;/p&gt;

&lt;p&gt;That’s where things start to diverge between the AI-generated approach and the human-built one.&lt;/p&gt;




&lt;p&gt;The AI solution leans heavily on CSS to handle the breathing animation. It defines a looping keyframe animation that scales the circle up and down, giving the illusion of inhale and exhale. On the surface, this feels clean and efficient. You describe the animation once, let it run infinitely, and your job seems done.&lt;/p&gt;

&lt;p&gt;But there’s a subtle flaw baked into that decision.&lt;/p&gt;

&lt;p&gt;CSS animations are autonomous. They don’t understand your application’s state. They don’t know whether the user has paused the session, changed a preset, or reset the cycle. They simply run.&lt;/p&gt;

&lt;p&gt;So while the animation continues smoothly, JavaScript tries to keep up by updating text and triggering phases using &lt;code&gt;setTimeout&lt;/code&gt;. These two systems—CSS and JavaScript—are now running in parallel, not in coordination.&lt;/p&gt;

&lt;p&gt;At first, everything appears fine. The timing seems close enough. But over multiple cycles, or under user interaction, small inconsistencies begin to show. The text might lag behind the animation. A pause might stop the UI visually but not logically. A reset might restart the text while the animation continues mid-cycle.&lt;/p&gt;

&lt;p&gt;None of these issues crash the app. That’s what makes them dangerous.&lt;/p&gt;

&lt;p&gt;They create an experience that feels slightly off, even if you can’t immediately explain why.&lt;/p&gt;




&lt;h2&gt;
  
  
  Then there’s the way time is handled in the AI-generated logic.
&lt;/h2&gt;

&lt;p&gt;Each phase schedules the next using &lt;code&gt;setTimeout&lt;/code&gt;. Inhale schedules hold, hold schedules exhale, and so on. It’s a chain of callbacks, each depending on the previous one to maintain flow.&lt;/p&gt;

&lt;p&gt;This works as long as nothing interrupts the chain.&lt;/p&gt;

&lt;p&gt;But real users interrupt everything.&lt;/p&gt;

&lt;p&gt;Click “Start” twice. Toggle pause rapidly. Switch presets mid-cycle. Now you have multiple timers running simultaneously, each unaware of the others. Some are still counting down from a previous state. Others are executing based on outdated assumptions.&lt;/p&gt;

&lt;p&gt;And because there’s no centralized control over these timers, they can’t be reliably canceled. They just keep firing.&lt;/p&gt;

&lt;p&gt;This is where the system begins to drift internally.&lt;/p&gt;

&lt;p&gt;You might see the UI reset, but somewhere in the background, an old timer is about to trigger an exhale phase that no longer makes sense. That’s when things start to feel inconsistent, even though nothing has technically “broken.”&lt;/p&gt;




&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6s14y7sca6plbxnfnfj8.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6s14y7sca6plbxnfnfj8.png" alt=" " width="800" height="365"&gt;&lt;/a&gt;&lt;br&gt;
The human implementation approaches this differently, and the difference is less about syntax and more about mindset.&lt;/p&gt;

&lt;p&gt;Instead of letting animation drive the experience, animation becomes a response to state.&lt;/p&gt;

&lt;p&gt;The system keeps track of what phase it is currently in—inhale, hold, exhale, or hold again—and transitions between them in a controlled manner. Each transition is deliberate. Each duration is respected. And most importantly, there is a single source of truth governing the entire flow.&lt;/p&gt;

&lt;p&gt;CSS is still used, but not as the engine. It handles transitions—how the circle moves from one size to another, how colors shift—but it doesn’t decide &lt;em&gt;when&lt;/em&gt; those transitions happen.&lt;/p&gt;

&lt;p&gt;That responsibility stays in JavaScript.&lt;/p&gt;

&lt;p&gt;This separation changes everything.&lt;/p&gt;

&lt;p&gt;Now, when the user pauses, the system doesn’t just stop visually—it stops logically. The timer controlling the current phase is cleared. No hidden callbacks remain. When the user resumes, the system continues from a known state, not from wherever the animation happened to be.&lt;/p&gt;

&lt;p&gt;When presets are introduced—short, medium, long—the durations adjust dynamically because the system is built to handle variable timing. The animation doesn’t need to be rewritten; it simply responds to new inputs.&lt;/p&gt;

&lt;p&gt;And because everything is coordinated through a central flow, the text, animation, and internal state remain aligned.&lt;/p&gt;

&lt;p&gt;That alignment is what makes the experience feel “right,” even if the user doesn’t consciously notice it.&lt;/p&gt;




&lt;h2&gt;
  
  
  There’s also a layer of technical risk here that often goes unnoticed, especially in frontend projects like this.
&lt;/h2&gt;

&lt;p&gt;When timers are not properly managed, they accumulate. Each &lt;code&gt;setTimeout&lt;/code&gt; that isn’t cleared becomes a potential future action waiting to execute. Over time, especially in an app that runs continuously, this can lead to multiple overlapping execution paths.&lt;/p&gt;

&lt;p&gt;It’s not just a performance issue—it’s a behavioral one.&lt;/p&gt;

&lt;p&gt;You start seeing race conditions where two parts of the system try to update the UI at the same time. One thinks it’s in the inhale phase, another thinks it’s time to exhale. The result is inconsistency, not failure.&lt;/p&gt;

&lt;p&gt;Similarly, relying on independent systems—like CSS animations and JavaScript timers—to stay in sync introduces a form of desynchronization that’s hard to debug. Each system works correctly on its own, but together they drift.&lt;/p&gt;

&lt;p&gt;And then there’s user interaction.&lt;/p&gt;

&lt;p&gt;Most implementations assume users will behave predictably. They’ll click start once, let the cycle run, maybe pause occasionally. But real users don’t follow scripts. They click quickly, change their minds, experiment with controls.&lt;/p&gt;

&lt;p&gt;Without proper guarding—checks that ensure the system is in a valid state before executing logic—these interactions can push the app into undefined territory.&lt;/p&gt;

&lt;p&gt;It doesn’t take much. A few rapid clicks can create overlapping timers. A reset during a transition can leave the system half-updated. These are the kinds of edge cases that separate a working demo from a reliable application.&lt;/p&gt;




&lt;h2&gt;
  
  
  What makes this challenge interesting is how quietly it exposes these issues.
&lt;/h2&gt;

&lt;p&gt;Nothing about it screams “complex.” There are no APIs, no databases, no heavy frameworks. Just HTML, CSS, and JavaScript.&lt;/p&gt;

&lt;p&gt;But that simplicity removes all abstraction. There’s nothing to hide behind. If your timing is off, you feel it. If your state management is weak, it shows. If your system isn’t resilient to interaction, it breaks in subtle ways.&lt;/p&gt;

&lt;p&gt;And that’s where the real lesson sits.&lt;/p&gt;

&lt;p&gt;The difference between the AI-generated solution and the human-built one isn’t just about correctness. Both can produce something that appears to work.&lt;/p&gt;

&lt;p&gt;The difference is in how they handle uncertainty.&lt;/p&gt;

&lt;p&gt;The AI solution constructs behavior step by step, focusing on making each part function. The human solution designs a system that can maintain integrity even when things don’t go as planned.&lt;/p&gt;

&lt;p&gt;One gives you an animation.&lt;/p&gt;

&lt;p&gt;The other gives you something closer to a product.&lt;/p&gt;

&lt;p&gt;If you take this challenge at face value, you’ll probably finish it quickly. You’ll see the circle move, the text update, and you’ll consider it done.&lt;/p&gt;

&lt;p&gt;But if you push a little further—if you test it under interaction, if you think about how it behaves over time, if you try to extend it—you’ll start to see where the real difficulty lies.&lt;/p&gt;

&lt;p&gt;And once you notice that, it becomes hard to unsee.&lt;/p&gt;

&lt;p&gt;This was never just about building a breathing app.&lt;/p&gt;

&lt;p&gt;It was about understanding how to coordinate time, state, and user behavior in a system that doesn’t naturally keep them aligned.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fk8jp8ivw235gpxpx8biv.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fk8jp8ivw235gpxpx8biv.png" alt=" " width="800" height="418"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you want to experience that difference yourself, try the challenge here:&lt;/p&gt;

&lt;p&gt;👉 &lt;a href="https://vibecodearena.ai/share/0b9a3f33-b2b5-40ab-9df0-cabf370bfca3" rel="noopener noreferrer"&gt;https://vibecodearena.ai/share/0b9a3f33-b2b5-40ab-9df0-cabf370bfca3&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;You’ll get something working fairly quickly.&lt;/p&gt;

&lt;p&gt;The real question is whether it keeps working… when you stop treating it like a demo and start treating it like something real.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>vibecodearena</category>
      <category>hackerearth</category>
      <category>softwaredevelopment</category>
    </item>
    <item>
      <title>When 100% Doesn’t Mean Equal: The Hidden Gap in AI Code Evaluation ft. Vibe Code Arena</title>
      <dc:creator>YASHWANTH REDDY K</dc:creator>
      <pubDate>Wed, 25 Mar 2026 18:27:05 +0000</pubDate>
      <link>https://dev.to/yashwanth_reddyk_ad8c405/when-100-doesnt-mean-equal-the-hidden-gap-in-ai-code-evaluation-ft-vibe-code-arena-225b</link>
      <guid>https://dev.to/yashwanth_reddyk_ad8c405/when-100-doesnt-mean-equal-the-hidden-gap-in-ai-code-evaluation-ft-vibe-code-arena-225b</guid>
      <description>&lt;p&gt;There’s something deeply misleading about a perfect score.&lt;/p&gt;

&lt;p&gt;You look at the evaluation panel—Security: 100, Code Quality: 100, Correctness: 100, Performance: 100, Accessibility: 100—and the instinctive conclusion is simple:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Both models did equally well.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;But when I ran a simple UI challenge inside &lt;strong&gt;vibe code arena&lt;/strong&gt;, that assumption fell apart almost instantly.&lt;/p&gt;

&lt;p&gt;Because despite identical scores across every measurable metric, the outputs didn’t feel the same.&lt;/p&gt;

&lt;p&gt;Not even close.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Challenge Was Intentionally Simple
&lt;/h2&gt;

&lt;p&gt;The task itself wasn’t complex:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Build a “Vibe Counter”&lt;/li&gt;
&lt;li&gt;Increment and decrement a number&lt;/li&gt;
&lt;li&gt;Change background color based on value&lt;/li&gt;
&lt;li&gt;Add a reset button&lt;/li&gt;
&lt;li&gt;Keep it clean, smooth, and polished&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This wasn’t meant to break models.&lt;/p&gt;

&lt;p&gt;It was meant to reveal them.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fz5p0ro7jqf6lhtthkun6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fz5p0ro7jqf6lhtthkun6.png" alt=" " width="800" height="436"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpseqel42di0dwwbei6b1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpseqel42di0dwwbei6b1.png" alt=" " width="800" height="438"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The Scoreboard Said “Tie”
&lt;/h2&gt;

&lt;p&gt;Both models—gpt-oss-20b and Llama-3.2-3b-Instruct—scored:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;100 in Security&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;100 in Code Quality&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;100 in Correctness&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;100 in Performance&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;100 in Accessibility&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;From a benchmarking perspective, this is a dead heat.&lt;/p&gt;

&lt;p&gt;No vulnerabilities. No logical errors. No performance issues.&lt;/p&gt;

&lt;p&gt;If you were evaluating this programmatically, there’s no reason to prefer one over the other.&lt;/p&gt;

&lt;h2&gt;
  
  
  But the UI Told a Different Story
&lt;/h2&gt;

&lt;p&gt;The moment you actually interact with the outputs, the illusion breaks.&lt;/p&gt;

&lt;p&gt;One implementation feels:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Smooth&lt;/li&gt;
&lt;li&gt;Responsive&lt;/li&gt;
&lt;li&gt;Intentionally designed&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The other feels:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Functional&lt;/li&gt;
&lt;li&gt;Static&lt;/li&gt;
&lt;li&gt;Mechanically complete&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Both are “correct.”&lt;/p&gt;

&lt;p&gt;Only one feels &lt;em&gt;alive&lt;/em&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  This Is the Problem with Metric-Only Evaluation
&lt;/h2&gt;

&lt;p&gt;Traditional evaluation systems are built around things that are easy to measure:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Does the code run?&lt;/li&gt;
&lt;li&gt;Does it produce the right output?&lt;/li&gt;
&lt;li&gt;Does it avoid errors?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These are necessary.&lt;/p&gt;

&lt;p&gt;But they are not sufficient.&lt;/p&gt;

&lt;p&gt;Because they completely ignore a critical dimension of software:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Experience&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And experience is where the real differences emerge.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnxuajbk2dra2is7ctt0y.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnxuajbk2dra2is7ctt0y.png" alt=" " width="800" height="481"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The Missing Metric: Interpretation
&lt;/h2&gt;

&lt;p&gt;What actually separated the two models wasn’t skill.&lt;/p&gt;

&lt;p&gt;It was interpretation.&lt;/p&gt;

&lt;p&gt;The prompt included this line:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Make it look clean and nice with some smooth animation”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Now here’s the interesting part:&lt;/p&gt;

&lt;p&gt;Both models &lt;em&gt;technically satisfied this&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;But only one model &lt;strong&gt;interpreted it deeply&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  One Model Thought:
&lt;/h3&gt;

&lt;blockquote&gt;
&lt;p&gt;“Add styling and make sure it works.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3&gt;
  
  
  The Other Thought:
&lt;/h3&gt;

&lt;blockquote&gt;
&lt;p&gt;“Add transitions, micro-interactions, and visual feedback.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That difference is not about correctness.&lt;/p&gt;

&lt;p&gt;It’s about &lt;strong&gt;how far the model goes beyond literal instructions&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Illusion of Completeness
&lt;/h2&gt;

&lt;p&gt;When a model scores 100 across all categories, it creates a sense of finality.&lt;/p&gt;

&lt;p&gt;Like there’s nothing left to evaluate.&lt;/p&gt;

&lt;p&gt;But in reality, those metrics are only capturing:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Structural correctness&lt;/li&gt;
&lt;li&gt;Surface-level quality&lt;/li&gt;
&lt;li&gt;Observable behavior&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;They are not capturing:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Design decisions&lt;/li&gt;
&lt;li&gt;User experience&lt;/li&gt;
&lt;li&gt;Subtle interaction quality&lt;/li&gt;
&lt;li&gt;Thoughtfulness in implementation&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;So you end up with something dangerous:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Two solutions that look identical on paper but diverge in practice.&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  Why UI Challenges Break the Illusion
&lt;/h2&gt;

&lt;p&gt;This is exactly why simple frontend challenges are so powerful.&lt;/p&gt;

&lt;p&gt;In backend or algorithmic problems:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;There’s usually a “correct” answer&lt;/li&gt;
&lt;li&gt;Evaluation is deterministic&lt;/li&gt;
&lt;li&gt;Differences are easier to quantify&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;But in UI problems:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;There is no single correct answer&lt;/li&gt;
&lt;li&gt;Quality is subjective&lt;/li&gt;
&lt;li&gt;Interpretation matters more than execution&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That’s where models start to reveal their &lt;em&gt;thinking patterns&lt;/em&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Engineering vs Product Thinking Divide
&lt;/h2&gt;

&lt;p&gt;What we’re really seeing here is a split between two modes of reasoning:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Engineering Thinking
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Focus on correctness&lt;/li&gt;
&lt;li&gt;Minimize complexity&lt;/li&gt;
&lt;li&gt;Do exactly what’s required&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  2. Product Thinking
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Focus on user experience&lt;/li&gt;
&lt;li&gt;Add small enhancements&lt;/li&gt;
&lt;li&gt;Optimize for feel, not just function&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Both models demonstrated strong engineering thinking.&lt;/p&gt;

&lt;p&gt;Only one leaned into product thinking.&lt;/p&gt;

&lt;p&gt;And current evaluation systems don’t reward that difference.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why This Matters (More Than It Seems)
&lt;/h2&gt;

&lt;p&gt;It’s easy to dismiss this as “just UI polish.”&lt;/p&gt;

&lt;p&gt;But in real-world software, this is exactly what defines quality.&lt;/p&gt;

&lt;p&gt;Users don’t care if your code scored 100 in:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Security&lt;/li&gt;
&lt;li&gt;Performance&lt;/li&gt;
&lt;li&gt;Accessibility&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;They care about:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Does it feel responsive?&lt;/li&gt;
&lt;li&gt;Does it feel smooth?&lt;/li&gt;
&lt;li&gt;Does it feel intentional?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And those are things metrics don’t measure.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Real Limitation Isn’t the Model—It’s the Benchmark
&lt;/h2&gt;

&lt;p&gt;The takeaway here isn’t that one model is flawed.&lt;/p&gt;

&lt;p&gt;It’s that our evaluation systems are incomplete.&lt;/p&gt;

&lt;p&gt;They assume:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;If everything measurable is perfect, the solution is perfect.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;But this experiment shows:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;You can have perfect metrics… and still have a better solution.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  What Should We Be Measuring Instead?
&lt;/h2&gt;

&lt;p&gt;This opens up an interesting question:&lt;/p&gt;

&lt;p&gt;How do we evaluate things like:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Smoothness of interaction&lt;/li&gt;
&lt;li&gt;UI responsiveness&lt;/li&gt;
&lt;li&gt;Design intuition&lt;/li&gt;
&lt;li&gt;Code maintainability beyond structure&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These are harder to quantify.&lt;/p&gt;

&lt;p&gt;But they’re not optional.&lt;/p&gt;

&lt;p&gt;They’re what separate:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;code that works&lt;/li&gt;
&lt;li&gt;from code that feels right&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Why You Should Start Designing Challenges Like This
&lt;/h2&gt;

&lt;p&gt;If you’re creating challenges on &lt;strong&gt;vibe code arena&lt;/strong&gt;, this is the direction to lean into.&lt;/p&gt;

&lt;p&gt;Instead of focusing only on:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;complex algorithms&lt;/li&gt;
&lt;li&gt;tricky edge cases&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Start exploring:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;ambiguous prompts&lt;/li&gt;
&lt;li&gt;UI/UX-driven tasks&lt;/li&gt;
&lt;li&gt;interpretation-heavy requirements&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Because that’s where:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;models diverge&lt;/li&gt;
&lt;li&gt;insights emerge&lt;/li&gt;
&lt;li&gt;real evaluation begins&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Foj3g6vtj560ijdej2ulb.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Foj3g6vtj560ijdej2ulb.png" alt=" " width="800" height="418"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Try It Yourself (And Look Beyond the Score)
&lt;/h2&gt;

&lt;p&gt;If you want to see this gap firsthand:&lt;/p&gt;

&lt;p&gt;👉 &lt;a href="https://vibecodearena.ai/share/75e5ac58-2e37-48d7-a140-48e0f9a93678" rel="noopener noreferrer"&gt;https://vibecodearena.ai/share/75e5ac58-2e37-48d7-a140-48e0f9a93678&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Don’t just look at the metrics.&lt;/p&gt;

&lt;p&gt;Interact with the output.&lt;/p&gt;

&lt;p&gt;That’s where the real answer is.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>vibecoding</category>
      <category>hackerearth</category>
      <category>programming</category>
    </item>
  </channel>
</rss>
