<?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: Dakshim Chhabra</title>
    <description>The latest articles on DEV Community by Dakshim Chhabra (@dakshim).</description>
    <link>https://dev.to/dakshim</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%2F776609%2Ff1138e7d-7e6a-48bd-ad9a-e7f9e556808b.jpeg</url>
      <title>DEV Community: Dakshim Chhabra</title>
      <link>https://dev.to/dakshim</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/dakshim"/>
    <language>en</language>
    <item>
      <title>From "Under Promise, Over Deliver" to thinking in systems</title>
      <dc:creator>Dakshim Chhabra</dc:creator>
      <pubDate>Thu, 26 Mar 2026 10:42:43 +0000</pubDate>
      <link>https://dev.to/dakshim/from-under-promise-over-deliver-to-thinking-in-systems-k6i</link>
      <guid>https://dev.to/dakshim/from-under-promise-over-deliver-to-thinking-in-systems-k6i</guid>
      <description>&lt;p&gt;&lt;em&gt;This is a submission for the &lt;a href="https://dev.to/challenges/wecoded-2026"&gt;2026 WeCoded Challenge&lt;/a&gt;: Echoes of Experience&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Back in 2019, Being an avid reader, I used to brag about having 120+ books in my mini library.&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%2F1pg4803mxlwz4468rcrq.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%2F1pg4803mxlwz4468rcrq.jpg" alt="Dakshim's mini library" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Yes a mini library, a quit, sacred space for an introvert me, It was my den; the place where I used to declutter my mind, recharge, and think.&lt;/p&gt;

&lt;h2&gt;
  
  
  Years of Chaos
&lt;/h2&gt;

&lt;p&gt;Then came the year 2020, during Covid Lockdown, chaos happened, and there was uncertainty all around.&lt;/p&gt;

&lt;p&gt;Amid fears of layoffs and ambiguity of working from home, collaborating remotely, I was promoted to lead a team of 4 entry-level developers.&lt;/p&gt;

&lt;p&gt;I threw myself into it, by upskilling the team in modern web technologies and remote collaboration tools.&lt;/p&gt;

&lt;p&gt;Word got out, People from other teams who wanted to learn JavaScript also joined my daily after-office classes.&lt;/p&gt;

&lt;p&gt;But then, reality bit. My organization underwent a massive restructuring, and a team of 40 got downsized to 22; I survived, but that survival came with a hidden tax.&lt;/p&gt;

&lt;h2&gt;
  
  
  Cost of Survival
&lt;/h2&gt;

&lt;p&gt;The survival comes with a cost, a cost where one event led to another,&lt;br&gt;
where imposter syndrome entered, along with people pleasing.&lt;/p&gt;

&lt;p&gt;As the only person left with full-stack experience in React and Laravel, my plate didn't just fill up; it overflowed. I was suddenly tasked with assisting Business Development to convert leads.&lt;/p&gt;

&lt;p&gt;As a first-timer, I followed what everyone says, the standard industry mantra: &lt;/p&gt;

&lt;p&gt;&lt;em&gt;&lt;strong&gt;Under-promise and over-deliver.&lt;/strong&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;What they don't tell you is that this advice comes with a &lt;strong&gt;"terms and conditions"&lt;/strong&gt; clause.&lt;/p&gt;

&lt;p&gt;When you over-deliver repeatedly to the same person, you aren't being a hero; you're setting a dangerous new baseline. You become taken for granted. &lt;/p&gt;

&lt;p&gt;In my case, over-delivering led to massive scope creep. The team I was supposed to lead started feeling the heat.&lt;/p&gt;

&lt;p&gt;I lost the mental space required to lead effectively.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Breaking Point
&lt;/h2&gt;

&lt;p&gt;The true cost of this "over-delivery" didn't just impact my code; it taxed my family.&lt;/p&gt;

&lt;p&gt;In August 2023, my father suffered his first brain stroke. It was a terrifying, grounding moment that laid bare the fragility of my "hustle." &lt;/p&gt;

&lt;p&gt;While I was busy over-delivering to clients who took me for granted, I was under-delivering to the people who actually mattered. &lt;/p&gt;

&lt;p&gt;I had lost the mental and emotional space required to be a lead at work, but more importantly, to be a son at home.&lt;/p&gt;

&lt;p&gt;The weight of being constantly "on" meant I was physically present but mentally absent when my family needed me most.&lt;/p&gt;

&lt;h2&gt;
  
  
  Reclaiming the Bookshelf
&lt;/h2&gt;

&lt;p&gt;Today, I'm in the process of reclaiming my time and my mental "den." It's a slow build back to that 2019 peace of mind, and I'm doing it through a new set of operating principles:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Setting Hard Boundaries&lt;/strong&gt;: My time is no longer an open-ended resource.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;The Art of 'No'&lt;/strong&gt;: Learning that saying "no" to a feature is often saying "yes" to quality and family.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Promising Rightly&lt;/strong&gt;: Moving away from the "over-deliver" trap and toward accurate, sustainable expectations.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Killing the Hype&lt;/strong&gt;: Eliminating buzzwords and stopping the chase for every new shiny framework.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Rigid Scoping&lt;/strong&gt;: Evaluating project boundaries with a critical eye before the first line of code is written.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Fundamentals First&lt;/strong&gt;: Building strategies and systems that are reliable, not just fast.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;My mini-library is still there. Now, I'm finally making sure I have the headspace to actually read the books in it and the time to be there for the people who hold my world together.&lt;/p&gt;

</description>
      <category>devchallenge</category>
      <category>wecoded</category>
      <category>dei</category>
      <category>career</category>
    </item>
    <item>
      <title>While setting up a Next.js project today,

I noticed AGENTS &amp; CLAUDE markdown files pointing to node_modules/next/dist/docs/.

Fascinating how the ecosystem evolving from monolithic to micro frontends.
and toward more integrated developer experiences.</title>
      <dc:creator>Dakshim Chhabra</dc:creator>
      <pubDate>Sat, 21 Mar 2026 20:04:44 +0000</pubDate>
      <link>https://dev.to/dakshim/while-setting-up-a-nextjs-project-today-i-noticed-agents-claude-markdown-files-pointing-to-1if4</link>
      <guid>https://dev.to/dakshim/while-setting-up-a-nextjs-project-today-i-noticed-agents-claude-markdown-files-pointing-to-1if4</guid>
      <description></description>
    </item>
    <item>
      <title>Observe, Ally and Grow : WeCoded Formula using SpinWheel</title>
      <dc:creator>Dakshim Chhabra</dc:creator>
      <pubDate>Fri, 20 Mar 2026 06:01:29 +0000</pubDate>
      <link>https://dev.to/dakshim/observe-ally-and-grow-wecoded-formula-using-spinwheel-eb4</link>
      <guid>https://dev.to/dakshim/observe-ally-and-grow-wecoded-formula-using-spinwheel-eb4</guid>
      <description>&lt;p&gt;&lt;em&gt;This is a submission for the &lt;a href="https://dev.to/challenges/wecoded-2026"&gt;2026 WeCoded Challenge&lt;/a&gt;: Frontend Art&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Ever wondered if our life, the situations we are in, Is it a lucky draw? Is it truly random, or is there some weighted randomness? &lt;/p&gt;

&lt;p&gt;My submission is a &lt;em&gt;&lt;strong&gt;"Spin Wheel | Wheel of Fortune"&lt;/strong&gt;&lt;/em&gt; that celebrates the randomness, the diversity, and reminds us that: &lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Inclusiveness is not random. Gender Equity is not random. But a choice, a choice of actions.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The three core actions are:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Look Back and Observe&lt;/strong&gt;: Observe and study the Legends, find the roadmap for innovation, the courage to raise our voice, and the fire to pioneer a revolution.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Look Out and act as an Ally&lt;/strong&gt;: Do everything possible to uplift capable yet underrepresented peers, making sure the strongest ideas rise above the loudest voices.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Look In and Grow&lt;/strong&gt;: When we encounter hurdles, we must draw on inner strength and a growth mindset; reminding ourselves that we belong here and refusing to surrender to the environment..&lt;/p&gt;

&lt;h2&gt;
  
  
  The Project: The Triple-Mode SpinWheel
&lt;/h2&gt;

&lt;p&gt;To celebrate the randomness in diversity and the deliberated action, the choice of inclusion, I have created an interactive experience that allows you to "Observe, Ally and Grow".&lt;/p&gt;

&lt;h3&gt;
  
  
  How it works:
&lt;/h3&gt;

&lt;p&gt;Use the central menu to toggle between three distinct modes of empowerment:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Observe Mode:&lt;/strong&gt; Discover the 10 voices, from Ada Lovelace to modern-day pioneers, who shattered the glass ceiling and shaped the history of Tech.&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%2Fsvdl7do455xlb2x9jpay.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%2Fsvdl7do455xlb2x9jpay.jpg" alt="Observe" width="700" height="700"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Ally Mode:&lt;/strong&gt; Step into a leadership role. This mode provides 10 actionable "micro-missions" to fight for diversity and equity within your organization.&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%2F31chspb3b8zn2aaa5wgf.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%2F31chspb3b8zn2aaa5wgf.jpg" alt="Ally" width="700" height="700"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Grow Mode:&lt;/strong&gt; A toolkit for the soul. When imposter syndrome strikes, spin for 10 powerful affirmations designed to help you break free from the boxes the world tries to put you in.&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%2Frq9ymw577u8plta448vj.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%2Frq9ymw577u8plta448vj.jpg" alt="Grow" width="700" height="700"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;em&gt;"Unity in Diversity"&lt;/em&gt; Background
&lt;/h2&gt;

&lt;p&gt;I want a background that reflects the unity in diversity of tech. A visual reminder of how people from every corner come together to make the world a better place.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;First Thought, why not use Avatars?&lt;/strong&gt;&lt;br&gt;
&lt;strong&gt;Second Thought, Why not reuse Avataaars Sketch Library&lt;/strong&gt; by &lt;a href="https://twitter.com/pablostanley" rel="noopener noreferrer"&gt;Pablo Stanley&lt;/a&gt; that I have used earlier in &lt;a href="https://dakshim.github.io/tippytippyavatar/" rel="noopener noreferrer"&gt;TippyTippy Avatar Generator&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Initially, I imagined a scrolling background of randomly generated avatars. To keep things optimized, I settled on 16 diverse avatars displayed at once. &lt;/p&gt;

&lt;p&gt;Still, in my pipeline is a more ambitious idea, a true random diversity background generator, continuously creating new faces to reflect the endless variety of people shaping tech.&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%2Fp5ggk340tzwhgb5eep20.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%2Fp5ggk340tzwhgb5eep20.jpg" alt="Unity in Diversity" width="800" height="392"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Easter Egg
&lt;/h2&gt;

&lt;p&gt;In mobile, I have included gesture support; you can switch between the modes by swiping left or right.&lt;/p&gt;

&lt;h2&gt;
  
  
  Show us your Art
&lt;/h2&gt;

&lt;p&gt;Demo Url : &lt;a href="https://wecoded-2026-spinwheel.netlify.app/" rel="noopener noreferrer"&gt;https://wecoded-2026-spinwheel.netlify.app/&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Inspiration
&lt;/h2&gt;

&lt;p&gt;While creating a &lt;a href="https://dev.to/dakshim/building-a-spin-wheel-part-1-random-digits-in-javascript-cryptogetrandomvalues-1g1b"&gt;SpinWheel &lt;/a&gt; project this week, I was in deep thought. Is our life, the situation we are in, a lucky draw? Is it predictable as &lt;code&gt;Math.random()&lt;/code&gt;, or is it truly random as &lt;code&gt;crypto.getRandomValues()&lt;/code&gt;? Or is there a weighted randomness that decides our destiny?&lt;/p&gt;

&lt;p&gt;I concluded that the randomness in the destiny is not truly random, but is weighted one. That cumulative weight is directly proportional to the action we take consciously or unconsciously. &lt;/p&gt;

&lt;p&gt;Why not re-program the wheel of life by this simple motto: &lt;strong&gt;&lt;em&gt;"We observe, we help, and we grow"&lt;/em&gt;&lt;/strong&gt;. &lt;/p&gt;

&lt;p&gt;Why not add a background representing how endless people, in tech daily contributing to make the industry a better place.&lt;/p&gt;

&lt;h2&gt;
  
  
  My Code
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://github.com/dakshim/wecoded2026-spinwheel" rel="noopener noreferrer"&gt;Code Repository&lt;/a&gt;&lt;/p&gt;

</description>
      <category>wecoded</category>
      <category>devchallenge</category>
      <category>frontend</category>
      <category>css</category>
    </item>
    <item>
      <title>Building a Spin Wheel - Part 2, Weighted Randomness: Cumulative Method</title>
      <dc:creator>Dakshim Chhabra</dc:creator>
      <pubDate>Tue, 17 Mar 2026 13:23:53 +0000</pubDate>
      <link>https://dev.to/dakshim/building-a-spin-wheel-part-2-weighted-randomness-cumulative-method-12id</link>
      <guid>https://dev.to/dakshim/building-a-spin-wheel-part-2-weighted-randomness-cumulative-method-12id</guid>
      <description>&lt;p&gt;In the last part, you have seen how we favored &lt;code&gt;crypto.getRandomValues()&lt;/code&gt; than &lt;code&gt;Math.random()&lt;/code&gt;. In this part, we'll be building a logic to provide us with weighted randomness using &lt;code&gt;crypto.getRandomValues()&lt;/code&gt;,&lt;/p&gt;

&lt;p&gt;For this, I started my logic by using &lt;code&gt;Uint8Array&lt;/code&gt;, but during research for a perfect algorithm, I came across a term known as &lt;strong&gt;aliasing&lt;/strong&gt;.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Though, I am still testing and researching on aliasing, but some discussions suggest that using low sample values while calculating the random value will impact the ability of the solution to be truly random.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Therefore, I proceeded with using &lt;code&gt;Uint32Array&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;First,&lt;/strong&gt; we'll be calculating a random value:&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;cryptoArray&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="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nb"&gt;window&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;cryptoArray&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;randomFloat&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;cryptoArray&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="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="o"&gt;**&lt;/span&gt;&lt;span class="mi"&gt;32&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here, for the sake of optimization, we can precalculate 2*&lt;em&gt;32 to be 4294967296 or create a constant that will hold the value of 2&lt;/em&gt;*32.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Second,&lt;/strong&gt; let's define the items as an array of JSON:&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;slices&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="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;label&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Grand Prize&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;weight&lt;/span&gt;&lt;span class="p"&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="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;label&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Better Luck Next Time&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;weight&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;40&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;label&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;5% Discount&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;weight&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;25&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;4&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;label&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Free Shipping&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;weight&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;30&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;strong&gt;Third,&lt;/strong&gt; we'll be calculating the total weight of all the items:&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;totalWeight&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;slices&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;reduce&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="nx"&gt;sum&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;i&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;sum&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;weight&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;To decide the winner, we are going to use the &lt;strong&gt;cumulative method&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  How does it work?
&lt;/h3&gt;

&lt;p&gt;Imagine we have a ruler or line of 100 units, where each item occupies its own length, respectively, of its weight. &lt;/p&gt;

&lt;p&gt;Starting from 0, if the weight of the item is 5, then it will take 5 units of length on the scale, and its starting point and ending point become 0-5. &lt;/p&gt;

&lt;p&gt;For the next item, we have a weight of 40; we'll be adding the same to the ending point of the previous item. The next item's starting point and ending point will become 5-45, and so on, as defined below:  &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;0-5 -&amp;gt; Grand Prize, &lt;/li&gt;
&lt;li&gt;5-45 -&amp;gt; Better Luck Next Time, &lt;/li&gt;
&lt;li&gt;45-70 -&amp;gt; 5% Discount, &lt;/li&gt;
&lt;li&gt;70-100 -&amp;gt; Free Shipping.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now, we'll calculate a targetValue by multiplying the randomFloat (from First Step) by the totalWeight (from the third step), so that it comes between 0 and 100.&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;targetValue&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;randomFloat&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="nx"&gt;totalWeight&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If randomFloat comes out to be 0.42 and totalWeight to be 100, then our targetValue would be 42. Now we'll check where the 42 lies on the scale. It lies between 5-45, i.e., "Better Luck Next Time".&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%2Fqw8en70oklu2yujrr2wd.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%2Fqw8en70oklu2yujrr2wd.png" alt="weighted-randomness-on-scale" width="800" height="187"&gt;&lt;/a&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;let&lt;/span&gt; &lt;span class="nx"&gt;cumulativeWeight&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="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;winner&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;startWeight&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="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;item&lt;/span&gt; &lt;span class="k"&gt;of&lt;/span&gt; &lt;span class="nx"&gt;items&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;startWeight&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;cumulativeWeight&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nx"&gt;cumulativeWeight&lt;/span&gt; &lt;span class="o"&gt;+=&lt;/span&gt; &lt;span class="nx"&gt;item&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;weight&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;targetValue&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;=&lt;/span&gt; &lt;span class="nx"&gt;cumulativeWeight&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nx"&gt;winner&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;item&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="k"&gt;break&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;h2&gt;
  
  
  What is Next?
&lt;/h2&gt;

&lt;p&gt;In the next parts, I'll be converting this logic to canvas based SpinWheel, and then we'll be creating a visual builder to customize the SpinWheel according to the requirements.&lt;/p&gt;

&lt;p&gt;Hopefully, if time allows, we'll be converting the same to the React Library, Shopify App and Wordpress Plugin.&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>beginners</category>
    </item>
    <item>
      <title>Building a Spin Wheel - Part 1, Random Digits in Javascript: Crypto.getRandomValues()</title>
      <dc:creator>Dakshim Chhabra</dc:creator>
      <pubDate>Sun, 15 Mar 2026 12:26:48 +0000</pubDate>
      <link>https://dev.to/dakshim/building-a-spin-wheel-part-1-random-digits-in-javascript-cryptogetrandomvalues-1g1b</link>
      <guid>https://dev.to/dakshim/building-a-spin-wheel-part-1-random-digits-in-javascript-cryptogetrandomvalues-1g1b</guid>
      <description>&lt;p&gt;When building a Lucky draw system, whether it's a Jackpot machine, spin wheel, or roulette, the key ingredient is &lt;strong&gt;&lt;em&gt;unpredictable randomness&lt;/em&gt;&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Most developers are naturally inclined to use &lt;code&gt;Math.random()&lt;/code&gt;. Why? &lt;em&gt;&lt;strong&gt;Awareness&lt;/strong&gt;&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;It is one of the methods that is taught in every JavaScript class.&lt;/li&gt;
&lt;li&gt;Many of us are not aware that it is not truly random and is predictable. &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It's based on a pseudo‑random number generator (like &lt;code&gt;xorshift128+&lt;/code&gt;), which means its sequence can be predicted. That's why secure systems, such as token generators, hashing methods, OTPs avoid it.&lt;/p&gt;

&lt;p&gt;While creating a SpinWheel last week, I hit the same challenge, If not &lt;code&gt;Math.random()&lt;/code&gt;, then how to get real randomness?&lt;/p&gt;

&lt;h2&gt;
  
  
  The answer : &lt;code&gt;window.crypto.getRandomValues()&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;This API provides cryptographically strong random values, far more secure than &lt;code&gt;Math.random()&lt;/code&gt;. It takes a typed array as input and returns a new array of the same type and length, filled with unpredictable numbers.&lt;/p&gt;

&lt;h2&gt;
  
  
  Usage
&lt;/h2&gt;

&lt;p&gt;Getting the random values&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;trulyRandom&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;Uint8Array&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;window&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;trulyRandom&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="nx"&gt;trulyRandom&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;Getting random values from a set of values&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="c1"&gt;// Example: Selecting from an array&lt;/span&gt;
&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;mySet&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Try Again&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="s1"&gt;20% Discount&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="s1"&gt;30% Discount&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="s1"&gt;40% Discount&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="s1"&gt;50% Discount&lt;/span&gt;&lt;span class="dl"&gt;'&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;trulyRandomFromSet&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;Uint8Array&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="nb"&gt;window&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;trulyRandomFromSet&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="c1"&gt;// Map to index (0-4)&lt;/span&gt;
&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;randomIndex&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;trulyRandomFromSet&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="nx"&gt;mySet&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;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="nx"&gt;mySet&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;If you're building anything where fairness or security matters, skip Math.random(), crypto is your friend.&lt;/p&gt;

&lt;h2&gt;
  
  
  Next Challenge: Weighted Outcomes
&lt;/h2&gt;

&lt;p&gt;To align the SpinWheel with campaign goals, equal probability isn't enough. &lt;/p&gt;

&lt;p&gt;I wanted 50% of users to land on "Try Again" and the other 50% on "Discount."&lt;/p&gt;

&lt;p&gt;There are two ways to achieve this:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Add more "Try Again" slots to the wheel.&lt;/li&gt;
&lt;li&gt;Or, implement weighted randomness in the logic, so results follow the desired distribution.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;If I choose to add more "Try Again",&lt;/em&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;then &lt;/p&gt;

&lt;p&gt;What about the weightage of other outcomes? &lt;br&gt;
What if I want that '50% Discount' should be reserved for only 1% of users? &lt;/p&gt;

&lt;p&gt;It will not be future compatible solution.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;In the next part, let's discuss how I can build a weighted randomness logic.&lt;/em&gt;&lt;/strong&gt;&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>beginners</category>
    </item>
    <item>
      <title>If you can read the manual, you can change the world</title>
      <dc:creator>Dakshim Chhabra</dc:creator>
      <pubDate>Thu, 12 Mar 2026 17:50:07 +0000</pubDate>
      <link>https://dev.to/dakshim/if-you-can-read-the-manual-you-can-change-the-world-43lo</link>
      <guid>https://dev.to/dakshim/if-you-can-read-the-manual-you-can-change-the-world-43lo</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;If you can blink an LED, you can change the world.&lt;br&gt;
But I believe, If you can read the manual, you can change the world.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Back in my college days, I was interested in Embedded System and Internet of Things, and loves to spend my pocket money on building new things.&lt;/p&gt;

&lt;p&gt;I used to run the simulation on Proteus, a software well known for simulating things and then on real device.&lt;/p&gt;

&lt;p&gt;On one occasion, I was building a scrolling text animation on dot matrix display using Arduino, which was working fine on Proteus, but failed on real device.&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%2Fu5148vzb3ocwmh66vtp3.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%2Fu5148vzb3ocwmh66vtp3.jpg" alt="Dakshim Scrolling Display using Arduino" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Frustrated, I turned to my mentor, a seasoned veteran. His advice was simple:&lt;br&gt;
"&lt;em&gt;&lt;strong&gt;Dakshim, have you read the display manual&lt;/strong&gt;&lt;/em&gt;".&lt;/p&gt;

&lt;p&gt;Me: But it is working fine on Proteus.&lt;br&gt;
He: Read the manual first.&lt;/p&gt;

&lt;p&gt;It turns out to be a common issue with that specific display that was mentioned on the very first page of the manual.&lt;/p&gt;

&lt;p&gt;Decade passed, but lesson remained. Read the Fabulous Manual&lt;/p&gt;

</description>
      <category>beginners</category>
      <category>programming</category>
      <category>learning</category>
    </item>
    <item>
      <title>TippyTippy Pregnancy Companion built with Google Gemini</title>
      <dc:creator>Dakshim Chhabra</dc:creator>
      <pubDate>Tue, 03 Mar 2026 11:54:29 +0000</pubDate>
      <link>https://dev.to/dakshim/tippytippy-pregnancy-companion-built-with-google-gemini-35am</link>
      <guid>https://dev.to/dakshim/tippytippy-pregnancy-companion-built-with-google-gemini-35am</guid>
      <description>&lt;p&gt;&lt;em&gt;This is a submission for the &lt;a href="https://dev.to/challenges/mlh/built-with-google-gemini-02-25-26"&gt;Built with Google Gemini: Writing Challenge&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;As an expecting father, one of the biggest challenges I faced during my wife's pregnancy was keeping track of everything: daily medicines, doctor appointments, weight, blood pressure, and all the weekly milestones. While information is readily available online, I found myself constantly retyping the same details: LMP date, test results, weight updates, scans, and so on.&lt;/p&gt;

&lt;h2&gt;
  
  
  What I Built with Google Gemini
&lt;/h2&gt;

&lt;p&gt;To simplify this journey, I created TippyTippy Pregnancy Companion using Gemini and Google AI Studio, a NextJS-based prototype app designed to streamline everything in one place.&lt;/p&gt;

&lt;p&gt;The prototype currently includes:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Authentication &amp;amp; data storage (using local storage)&lt;/li&gt;
&lt;li&gt;Appointment &amp;amp; medicine scheduling&lt;/li&gt;
&lt;li&gt;Pregnancy timeline calculator based on LMP&lt;/li&gt;
&lt;li&gt;Weekly milestone details with tips and expectations&lt;/li&gt;
&lt;li&gt;Vitals logging (blood pressure and weight tracking)&lt;/li&gt;
&lt;li&gt;AI-powered companion for insights and questions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Planned features for the next phase:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Google Health Companion integration to sync vitals from smartwatches&lt;/li&gt;
&lt;li&gt;Image reader for scanning prescriptions and auto-filling details&lt;/li&gt;
&lt;li&gt;Firebase integration for secure data storage and cloud sync&lt;/li&gt;
&lt;li&gt;HIPAA compliance and other regulatory considerations&lt;/li&gt;
&lt;li&gt;Refined AI prompts &amp;amp; edge-case handling&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Demo
&lt;/h2&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%2Flkrvozbk419k8pfnpl8e.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%2Flkrvozbk419k8pfnpl8e.png" alt="Pregnancy Companion in NextJs" width="800" height="450"&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%2Flw4wxo4m3zg21k5b2wjm.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%2Flw4wxo4m3zg21k5b2wjm.png" alt="Pregnancy Companion in NextJs" width="800" height="450"&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%2F1sktpl7jdo2v5fk5r9p6.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%2F1sktpl7jdo2v5fk5r9p6.png" alt="Pregnancy Companion in NextJs" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  What I Learned
&lt;/h2&gt;

&lt;p&gt;The things that I learned were beyond technology that evolved me to be a more empathetic being and humbled me as a person:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Seeing how a life evolves from the size of a pea to the size of a watermelon.&lt;/li&gt;
&lt;li&gt;How do mood swings happen?&lt;/li&gt;
&lt;li&gt;How can accidentally lifting a heavy object and suffering from typhoid put the whole journey at risk?&lt;/li&gt;
&lt;li&gt;And why it is important to deal with situations with empathy and a positive manner, and why panicking can spoil things.&lt;/li&gt;
&lt;li&gt;How to hold a baby? How to change a diaper and so on.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Apart from these, technically, I learnt:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Prompt Engineering&lt;/strong&gt;: How adding a few details can change the output accuracy returned by Google Gemini.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;UI/UX&lt;/strong&gt;: While going through pregnancy, a couple is often in panic mode, I need to think as an expecting mother or as a father, who needs information at a glance, or needs to check schedule while going through day to day life, Though not quite right now in prototype version, an intuitive User Experience can make things accessible and easy.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Security&lt;/strong&gt;: I learnt how important it is to secure the app and the data&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Security is what held me back from releasing the App publicly. From other types of records, Health information is the most sensitive one.&lt;/p&gt;

&lt;p&gt;There are practices such as Encryption at Rest, Encryption at Transfer, and End-to-End Encryption, and then HIPAA compliance. A minute leak about a health condition can be exploited and misused.&lt;/p&gt;

&lt;p&gt;Currently, I am learning more about making things secure, and side by side implementing the same in the app.&lt;/p&gt;

&lt;h2&gt;
  
  
  Google Gemini Feedback
&lt;/h2&gt;

&lt;p&gt;Google Gemini is an excellent pair programmer when used right and given the correct context. Though there is scope for improvement, the major areas that might need immediate attention are:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Dates&lt;/strong&gt;: There are multiple methods to calculate expected due dates, Gemini seems to occasionally confuse between them.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Hallucination&lt;/strong&gt;: Sometimes, it hallucinates that a fix has been implemented, but in reality, there is no change in the code.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Reinvent the wheels&lt;/strong&gt;: Gemini by default shies away from popular npm packages and tries to recreate them from scratch, both in Google AI Studio and Google Anti-Gravity&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I overcame these issues by proactively reminding the Gemini about the dates, the methodology, and to tackle the hallucination, I followed the Chain of Thought prompting technique.&lt;/p&gt;

</description>
      <category>devchallenge</category>
      <category>geminireflections</category>
      <category>gemini</category>
      <category>nextjs</category>
    </item>
    <item>
      <title>NextJs v12 to NextJs v16 : Lesson learnt, Apart from following official method, check for dependencies upgrade guide.</title>
      <dc:creator>Dakshim Chhabra</dc:creator>
      <pubDate>Fri, 27 Feb 2026 10:42:32 +0000</pubDate>
      <link>https://dev.to/dakshim/nextjs-v12-to-nextjs-v16-lesson-learnt-apart-from-following-official-method-check-for-2970</link>
      <guid>https://dev.to/dakshim/nextjs-v12-to-nextjs-v16-lesson-learnt-apart-from-following-official-method-check-for-2970</guid>
      <description>&lt;p&gt;I was upgrading NextJS v12 to NextJS v16. &lt;br&gt;
I followed the upgrade guide step by step.&lt;br&gt;
I run all required codemods.&lt;/p&gt;

&lt;p&gt;I upgraded all the dependencies to the latest versions by running &lt;code&gt;yarn upgrade&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;The app is running fine, but somewhere in the corner, there is this unknown bug, which is hard to trace.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Runtime Error

Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: undefined. You
likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.

Check the render method of 'N'.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Every test passed, but upon doing manual testing, there was an error upon clicking the subscribe button.&lt;/p&gt;

&lt;p&gt;At this point, intuition kicks in. Why not pinpoint the problematic code?&lt;br&gt;
Why not check all the libraries used in that piece of code?&lt;/p&gt;

&lt;p&gt;Sometimes, In nextJs and reactJs the dependencies also have their own upgrade guides that we must follow.&lt;/p&gt;

&lt;p&gt;In my case, it was &lt;code&gt;react-toastify&lt;/code&gt;, upon subscription, I was using &lt;code&gt;react-toastify&lt;/code&gt; to dispatch a toast notification, and I forgot to follow its upgrade guide during the migration. Have you ever faced such errors? How do you tackle them?&lt;/p&gt;

</description>
      <category>nextjs</category>
      <category>testing</category>
    </item>
    <item>
      <title>Research Before VibeCoding: Libraries and Frameworks</title>
      <dc:creator>Dakshim Chhabra</dc:creator>
      <pubDate>Thu, 26 Feb 2026 14:57:17 +0000</pubDate>
      <link>https://dev.to/dakshim/research-before-vibecoding-libraries-and-frameworks-kb1</link>
      <guid>https://dev.to/dakshim/research-before-vibecoding-libraries-and-frameworks-kb1</guid>
      <description>&lt;p&gt;Today, I was cleaning up a vibe-coded project in NextJS, with a custom hook for validating and handling Form Submission, i.e., &lt;code&gt;useForm&lt;/code&gt;.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Form works? Yes, but only for small forms.&lt;/li&gt;
&lt;li&gt;Is it maintainable? Might be.&lt;/li&gt;
&lt;li&gt;Is it scalable? No.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;For complex forms, it was giving an error related to rendering, &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%2Fk1ro08l3m65yb6ptjyrf.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%2Fk1ro08l3m65yb6ptjyrf.jpg" alt="Rendering Error" width="800" height="352"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  I failed to fix the issue
&lt;/h2&gt;

&lt;p&gt;I tried for an hour to untangle the spaghetti, but failed. &lt;/p&gt;

&lt;p&gt;Used AI tools, but was unable to fix it. Moreover, AI even hallucinated that it solved the issue.&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%2Frzfhxdql4esnz7rzf2xc.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%2Frzfhxdql4esnz7rzf2xc.jpg" alt="AI Hallucination" width="427" height="819"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The Last Resort
&lt;/h2&gt;

&lt;p&gt;As a last resort, I have 2 choices: &lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;either to recreate the custom hook from scratch, &lt;/li&gt;
&lt;li&gt;or use well known library such as &lt;code&gt;Formik&lt;/code&gt; and &lt;code&gt;Yup&lt;/code&gt;.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  I chose to go with libraries. Why?
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;I don't want to reinvent the wheel, solving every known edge case/corner case, and testing the forms in major browsers.&lt;/li&gt;
&lt;li&gt;These libraries are well maintained from years.&lt;/li&gt;
&lt;li&gt;Clear and easy to read documentation.&lt;/li&gt;
&lt;li&gt;Easy to upgrade to future ReactJS versions&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Verdict
&lt;/h2&gt;

&lt;p&gt;Before diving into coding, make sure to research whether the feature you're building is already supported by any established libraries or frameworks.&lt;/p&gt;

</description>
      <category>codequality</category>
      <category>nextjs</category>
      <category>react</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Vibe coding React Color Picker using Google Antigravity</title>
      <dc:creator>Dakshim Chhabra</dc:creator>
      <pubDate>Tue, 24 Feb 2026 08:27:14 +0000</pubDate>
      <link>https://dev.to/dakshim/vibe-coding-react-color-picker-using-google-antigravity-198m</link>
      <guid>https://dev.to/dakshim/vibe-coding-react-color-picker-using-google-antigravity-198m</guid>
      <description>&lt;p&gt;I vibe-coded an MVP version of Color Picker this weekend for my ReactJS/NextJS projects using Google Antigravity. It was less of a self-test of JavaScript and more of a challenge to myself, to see if I can use Prompt Engineering to build something that is commonly used in my projects.&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%2Fjts4rhe5ogszs2y5w3m1.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%2Fjts4rhe5ogszs2y5w3m1.jpg" alt="React Color Picker" width="683" height="710"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;After initial research, to make it framework independent, and to keep everything in Shadow DOM, I finalized using Lit, Open Web Components, and Rollup module bundler.&lt;/p&gt;

&lt;h2&gt;
  
  
  Salient Features:
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Eye Dropper using Chrome EyeDropper API&lt;/li&gt;
&lt;li&gt;HTML Form Compatibility using ElementInternals Interface&lt;/li&gt;
&lt;li&gt;HEX, RGBa output &lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Upcoming Features:
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Canvas-based fallback EyeDropper for Firefox&lt;/li&gt;
&lt;li&gt;Multiple layouts for better accessibility&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Initial Prompt Used:
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Role&lt;/strong&gt;&lt;br&gt;
Act as a senior frontend architect. Scaffold a universal UI library for a color picker using the Open Web Components generator and Lit&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Instructions&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Create a universal color picker library where output must be  that works natively in jQuery, ReactJS (handle events via props), and NuxtJS, NextJS (handle window undefined checks) using Web Component API. &lt;/li&gt;
&lt;li&gt;It should use Lit and the open web components generator as a starting point.&lt;/li&gt;
&lt;li&gt;There must be no external dependencies. It should be compiler independent, should not use Vite, Babbel, or turbopack, or any kind of CSS loader. &lt;/li&gt;
&lt;li&gt;All CSS must be self-contained, encapsulated within the component (no separate .css file)&lt;/li&gt;
&lt;li&gt;Build output should be an ESM module and a UMD bundle&lt;/li&gt;
&lt;li&gt;It should use the rollup, rollup.config.js must be configured to ensure this 'compiler-independent distribution.' &lt;/li&gt;
&lt;li&gt;Implement a standard CustomEvent (e.g., color-change that bubbles and is composed to cross the Shadow root boundary&lt;/li&gt;
&lt;li&gt;Implement a Web Test Runner, also use @open-wc/testing-helpers to run automated accessibility audits&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Gaurdrails&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;NextJs and Nuxt execute code on the server where window and document do not exists, ensure all browser-specific API's (window, document, customElements are wrapped in checks or executed only after the component has mounted&lt;/li&gt;
&lt;li&gt;The library must be importable in a Node.js environment without throwing "ReferenceError: window is not defined."&lt;/li&gt;
&lt;li&gt;The component must use bubble: true and composed: true for all CustomEvents. For React, provide a small wrapper or using Ref to ensure seamless event binding in React 18/19&lt;/li&gt;
&lt;li&gt;Avoid importing heavy external color-math libraries, write lightweight internal utilities instead&lt;/li&gt;
&lt;li&gt;Strictly use shadow dom for style encapsulations&lt;/li&gt;
&lt;li&gt;If user puts &lt;code&gt;&amp;lt;color-picker&amp;gt;&lt;/code&gt; inside a &lt;code&gt;&amp;lt;form&amp;gt;&lt;/code&gt;, it should behave like a native  using ElementInternals API&lt;/li&gt;
&lt;li&gt;Do not build a wrapper around the native color picker input element; it should be a custom HTML element with swatches, hue slider, and hex input&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Refinements to the Journey
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Initially, Google Antigravity got confused and tried adding all the OpenWebComponent tools independently, such as Lit, Rollup. &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Therefore, I preferred to install the packages manually. &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Initial UI from the above prompt was not user friendly, therefore I used other AI tools to create a simple HTML UI and passed the same to Google Antigravity.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The Gradient generation was not upto the mark, this is something that I have fixed manually &lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Further Steps
&lt;/h2&gt;

&lt;p&gt;Over the next few days, I'll be refactoring the code to be more human-friendly and will spend time understanding the basic maths behind color conversion to make it scalable and maintainable in the future.&lt;/p&gt;

</description>
      <category>vibecoding</category>
      <category>antigravity</category>
      <category>react</category>
    </item>
    <item>
      <title>From Newspapers to Code Reviews: A Gratitude Story</title>
      <dc:creator>Dakshim Chhabra</dc:creator>
      <pubDate>Thu, 04 Sep 2025 06:00:00 +0000</pubDate>
      <link>https://dev.to/dakshim/from-newspapers-to-code-reviews-a-gratitude-story-il7</link>
      <guid>https://dev.to/dakshim/from-newspapers-to-code-reviews-a-gratitude-story-il7</guid>
      <description>&lt;p&gt;Back in 2018, when I joined Swap Development Pvt. Ltd., I expected my first tasks to revolve around Laravel development.&lt;/p&gt;

&lt;p&gt;Instead, my Team Lead gave me something unexpected:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Read newspapers&lt;/li&gt;
&lt;li&gt;Go through manuals &amp;amp; documentation&lt;/li&gt;
&lt;li&gt;Rewrite them in a short and precise manner&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;At first, I wondered: &lt;em&gt;"Why am I doing this instead of coding?"&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;But over time, I started noticing the impact.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;My reading speed improved.&lt;/li&gt;
&lt;li&gt;My writing became concise.&lt;/li&gt;
&lt;li&gt;Most importantly, my critical thinking sharpened.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;On some days, he even asked me to test my typing speed.&lt;br&gt;
I began at &lt;strong&gt;15 words per minute with 95% accuracy&lt;/strong&gt;, and gradually reached &lt;strong&gt;30 words per minute with 98% accuracy&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Looking back, those exercises weren't just tasks; they were the foundations of being a better developer.&lt;/p&gt;

&lt;p&gt;Because in reality, software development isn't just about writing code.&lt;br&gt;
It's about:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Reading documentation quickly&lt;/li&gt;
&lt;li&gt;Understanding problems deeply&lt;/li&gt;
&lt;li&gt;Writing solutions clearly&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That early training turned me into an avid reader, and it still helps me review code more efficiently, debug more effectively, and learn from documentation without frustration.&lt;/p&gt;

&lt;p&gt;I'm deeply grateful to my Team Lead for teaching me this lesson early in my career:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;👉 Strong reading and writing skills make you a stronger developer and leader.&lt;/p&gt;
&lt;/blockquote&gt;

</description>
      <category>careerdevelopment</category>
      <category>leadership</category>
      <category>gratitude</category>
      <category>beginners</category>
    </item>
    <item>
      <title>Retries, Dead Letter Queues &amp; Parking Lot: API Integration Essentials</title>
      <dc:creator>Dakshim Chhabra</dc:creator>
      <pubDate>Sat, 30 Aug 2025 10:55:50 +0000</pubDate>
      <link>https://dev.to/dakshim/retries-dead-letter-queues-parking-lot-api-integration-essentials-2g8d</link>
      <guid>https://dev.to/dakshim/retries-dead-letter-queues-parking-lot-api-integration-essentials-2g8d</guid>
      <description>&lt;p&gt;Imagine&lt;/p&gt;

&lt;blockquote&gt;
&lt;ul&gt;
&lt;li&gt;You created a Chat App using ReactJs or NextJs, built APIs using NodeJs, and integrated everything.&lt;/li&gt;
&lt;li&gt;You're happy and excited to try it out with your best friend.&lt;/li&gt;
&lt;li&gt;You type:
&lt;strong&gt;&lt;em&gt;If you can send data over API, you can change the world.&lt;/em&gt;&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;But then… your API throws an error.&lt;/li&gt;
&lt;li&gt;Now what? Should you try again? Should you drop the message? Or maybe hold it for later?&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;

&lt;p&gt;In distributed systems, automations and frontend apps, error handling is as important as the successful transmission of data.&lt;/p&gt;

&lt;p&gt;This is where concepts like &lt;strong&gt;Retries&lt;/strong&gt;, &lt;strong&gt;Dead Letter Queue (DLQ)&lt;/strong&gt;, and &lt;strong&gt;Parking Lot&lt;/strong&gt; come into play. Let's understand this using Courier service as an analogy.&lt;/p&gt;

&lt;h2&gt;
  
  
  Retries (Multiple Delivery Attempts)
&lt;/h2&gt;

&lt;p&gt;Imagine a courier comes to your house with a parcel. You're not home.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;They'll try again in the evening.&lt;/li&gt;
&lt;li&gt;Maybe one more time the next day.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That's a retry.&lt;/p&gt;

&lt;p&gt;In programming, retries handle temporary failures (like network glitches).&lt;/p&gt;

&lt;h2&gt;
  
  
  Dead Letter Queue (Return to Sender)
&lt;/h2&gt;

&lt;p&gt;What if the courier tries 3 times but still can't deliver? (wrong address, recipient unknown).&lt;br&gt;
The parcel is marked undeliverable and sent back to the sender.&lt;/p&gt;

&lt;p&gt;That's a Dead Letter Queue (DLQ), a special place where failed messages live for inspection.&lt;/p&gt;

&lt;p&gt;In backend systems, DLQs are common in RabbitMQ, Kafka, AWS SQS, etc.&lt;/p&gt;

&lt;h2&gt;
  
  
  Parking Lot (Delivery Paused Until You're Ready)
&lt;/h2&gt;

&lt;p&gt;Now imagine this:&lt;br&gt;
Courier calls you. You say, &lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;I'm on vacation, deliver it Monday.&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The parcel is held at the local hub until you're available.&lt;/p&gt;

&lt;p&gt;That's a Parking Lot Queue, messages are not lost, just waiting to be retried later.&lt;/p&gt;

&lt;h2&gt;
  
  
  Takeaway
&lt;/h2&gt;

&lt;p&gt;Next time you hear "Retries, DLQ, Parking Lot", just think of your courier guy:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Multiple delivery attempts = Retries&lt;/li&gt;
&lt;li&gt;Return to sender = DLQ&lt;/li&gt;
&lt;li&gt;Hold until Monday = Parking Lot&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And remember: graceful error handling is just as important as success paths, whether you're building with React, Node.js, or distributed systems or an automation using n8n.io or make.com.&lt;/p&gt;

</description>
      <category>programming</category>
      <category>beginners</category>
      <category>eventdriven</category>
      <category>api</category>
    </item>
  </channel>
</rss>
