<?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: Muhammad Ayoub Khan</title>
    <description>The latest articles on DEV Community by Muhammad Ayoub Khan (@ayoubkhan558).</description>
    <link>https://dev.to/ayoubkhan558</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%2F493647%2F692350e4-4d5d-4076-a8c8-57822f103147.png</url>
      <title>DEV Community: Muhammad Ayoub Khan</title>
      <link>https://dev.to/ayoubkhan558</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ayoubkhan558"/>
    <language>en</language>
    <item>
      <title>Seeking a Dev Buddy — Not Just a Partner in Code 💬🤝💻</title>
      <dc:creator>Muhammad Ayoub Khan</dc:creator>
      <pubDate>Sun, 25 May 2025 10:26:29 +0000</pubDate>
      <link>https://dev.to/ayoubkhan558/seeking-a-dev-buddy-not-just-a-partner-in-code-2j6l</link>
      <guid>https://dev.to/ayoubkhan558/seeking-a-dev-buddy-not-just-a-partner-in-code-2j6l</guid>
      <description>&lt;p&gt;Hey DEV fam! 👋 &lt;/p&gt;

&lt;p&gt;I’m &lt;strong&gt;M. Ayoub&lt;/strong&gt;, a front-end dev from _Faisalabad, Pakistan _with 3.5 years of experience. I love clean UI, solid UX, and late-night coding jams.&lt;/p&gt;

&lt;p&gt;Lately, I’ve been craving more than solo work—someone to build cool stuff, bounce ideas, vent about bugs, or just code quietly on a call.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;You might be the one if:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You’re a front-end dev (React, Next, JS, etc.)&lt;/li&gt;
&lt;li&gt;You love the craft&lt;/li&gt;
&lt;li&gt;You’re chill, curious, and consistent&lt;/li&gt;
&lt;li&gt;You're in for real friendship—not just networking&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I’m all about loyalty, learning, and genuine connection.&lt;br&gt;
If this sounds like your vibe, drop a comment or hit me up via GitHub/Twitter/WhatsApp.&lt;/p&gt;

&lt;p&gt;Let’s build, vibe, and grow—together. ✨❤️&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>webdev</category>
      <category>frontend</category>
      <category>html</category>
    </item>
    <item>
      <title>Looking for a Real Dev Friend — Not Just a Collab 🤝💻</title>
      <dc:creator>Muhammad Ayoub Khan</dc:creator>
      <pubDate>Sun, 25 May 2025 10:25:25 +0000</pubDate>
      <link>https://dev.to/ayoubkhan558/looking-for-a-real-dev-friend-not-just-a-collab-4lbm</link>
      <guid>https://dev.to/ayoubkhan558/looking-for-a-real-dev-friend-not-just-a-collab-4lbm</guid>
      <description>&lt;p&gt;Hey DEV fam! 👋 &lt;/p&gt;

&lt;p&gt;I’m &lt;strong&gt;M. Ayoub&lt;/strong&gt;, a front-end dev from _Faisalabad, Pakistan _with 3.5 years of experience. I love clean UI, solid UX, and late-night coding jams.&lt;/p&gt;

&lt;p&gt;Lately, I’ve been craving more than solo work—someone to build cool stuff, bounce ideas, vent about bugs, or just code quietly on a call.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;You might be the one if:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;You’re a front-end dev (React, Next, JS, etc.)&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You love the craft&lt;/li&gt;
&lt;li&gt;You’re chill, curious, and consistent&lt;/li&gt;
&lt;li&gt;You're in for real friendship—not just networking&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I’m all about loyalty, learning, and genuine connection.&lt;br&gt;
If this sounds like your vibe, drop a comment or hit me up via GitHub/Twitter/WhatsApp.&lt;/p&gt;

&lt;p&gt;Let’s build, vibe, and grow—together. ✨❤️&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>webdev</category>
      <category>frontend</category>
      <category>html</category>
    </item>
    <item>
      <title>HTML5 Semantic Tags: A Guide to Better Document Structure 🌐</title>
      <dc:creator>Muhammad Ayoub Khan</dc:creator>
      <pubDate>Fri, 03 May 2024 02:43:20 +0000</pubDate>
      <link>https://dev.to/ayoubkhan558/html5-semantic-tags-a-guide-to-better-document-structure-25p</link>
      <guid>https://dev.to/ayoubkhan558/html5-semantic-tags-a-guide-to-better-document-structure-25p</guid>
      <description>&lt;p&gt;In the dynamic landscape of web development, harnessing the power of HTML5 semantic tags is akin to sculpting a masterpiece – a website that not only captivates but also communicates effortlessly with users and search engines alike. Let's embark on a journey through the realm of semantic markup, exploring its myriad benefits and practical applications.&lt;/p&gt;

&lt;h2&gt;
  
  
  Unveiling the Essence of Semantic Tags
&lt;/h2&gt;

&lt;p&gt;HTML5 ushered in a new era of web semantics, bestowing upon developers a treasure trove of tags that lend meaning and structure to content. Enter the realm of , , , , , , , and  – the building blocks of a beautifully orchestrated web symphony.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Virtues of Semantic Tags:
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Accessibility: Semantic tags serve as beacons of clarity for assistive technologies, ensuring that users of all abilities can navigate and comprehend web content seamlessly.&lt;/li&gt;
&lt;li&gt;SEO Sorcery: Search engine wizards decipher the language of semantic HTML, rewarding well-structured pages with higher visibility and coveted top spots in search results.&lt;/li&gt;
&lt;li&gt;Readability Renaissance: Embracing semantic markup bestows upon code a newfound elegance, enhancing legibility and simplifying maintenance for developers.&lt;/li&gt;
&lt;li&gt;Future-proof Foundations: Semantic tags are not mere artifacts of the past; they are beacons guiding us towards a future where web standards evolve harmoniously with emerging technologies.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Illuminating the Path with Practical Examples
&lt;/h2&gt;

&lt;p&gt;Let's illuminate the path to semantic enlightenment with practical examples that showcase the versatility and elegance of semantic HTML.&lt;/p&gt;

&lt;h4&gt;
  
  
  Example 1: Crafting a Majestic Header
&lt;/h4&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;header&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;h1&amp;gt;&lt;/span&gt;Welcome to My Enchanted Realm&lt;span class="nt"&gt;&amp;lt;/h1&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;nav&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;ul&amp;gt;&lt;/span&gt;
      &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&amp;lt;a&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"#"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Home&lt;span class="nt"&gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
      &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&amp;lt;a&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"#"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;About&lt;span class="nt"&gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
      &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&amp;lt;a&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"#"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Services&lt;span class="nt"&gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
      &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&amp;lt;a&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"#"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Contact&lt;span class="nt"&gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/ul&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/nav&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/header&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  Example 2: Enshrining Content within  and 
&lt;/h4&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;main&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;section&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;h2&amp;gt;&lt;/span&gt;Tales of Wonder: Featured Stories&lt;span class="nt"&gt;&amp;lt;/h2&amp;gt;&lt;/span&gt;
    &lt;span class="c"&gt;&amp;lt;!-- Exquisite story snippets or enchanting imagery --&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/section&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;section&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;h2&amp;gt;&lt;/span&gt;Wisdom Unveiled: Latest Insights&lt;span class="nt"&gt;&amp;lt;/h2&amp;gt;&lt;/span&gt;
    &lt;span class="c"&gt;&amp;lt;!-- Enlightening articles or pearls of wisdom --&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/section&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/main&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  Example 3: Chronicles of Knowledge with 
&lt;/h4&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;article&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;header&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;h2&amp;gt;&lt;/span&gt;The Chronicles of Enlightenment: A Journey Within&lt;span class="nt"&gt;&amp;lt;/h2&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;Published on &lt;span class="nt"&gt;&amp;lt;time&lt;/span&gt; &lt;span class="na"&gt;datetime=&lt;/span&gt;&lt;span class="s"&gt;"2024-05-03"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;May 3, 2024&lt;span class="nt"&gt;&amp;lt;/time&amp;gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/header&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;Embark on a quest for wisdom as we unravel the mysteries of the universe...&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;footer&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;Scribed by Lorem Ipsum&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/footer&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/article&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  Example 4: Footer Flourishes
&lt;/h4&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;footer&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;&lt;span class="ni"&gt;&amp;amp;copy;&lt;/span&gt; 2024 My Enchanted Realm. All rights reserved.&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;nav&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;ul&amp;gt;&lt;/span&gt;
      &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&amp;lt;a&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"#"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Privacy Enchantment&lt;span class="nt"&gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
      &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&amp;lt;a&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"#"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Terms of Spellbinding&lt;span class="nt"&gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
      &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&amp;lt;a&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"#"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Contact the Oracle&lt;span class="nt"&gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/ul&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/nav&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/footer&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Embarking on a Semantic Odyssey 🚀🌟
&lt;/h2&gt;

&lt;p&gt;Incorporating HTML5 semantic tags into your web development odyssey elevates your creations to realms of unparalleled elegance and functionality. Embrace the magic of semantic markup to craft enchanting web experiences that resonate with users and enchant search engine algorithms alike. Let your code tell a story – one of clarity, accessibility, and enduring beauty. 🎨✨&lt;/p&gt;

</description>
      <category>html</category>
      <category>webdev</category>
      <category>layout</category>
    </item>
    <item>
      <title>Implementing Very Basic Dark/Light Modes with CSS Variables and JavaScript 🌓</title>
      <dc:creator>Muhammad Ayoub Khan</dc:creator>
      <pubDate>Fri, 03 May 2024 02:17:48 +0000</pubDate>
      <link>https://dev.to/ayoubkhan558/implementing-dark-and-light-modes-with-css-variables-and-javascript-d4n</link>
      <guid>https://dev.to/ayoubkhan558/implementing-dark-and-light-modes-with-css-variables-and-javascript-d4n</guid>
      <description>&lt;h2&gt;
  
  
  Introduction:
&lt;/h2&gt;

&lt;p&gt;In this tutorial, we'll walk through the process of implementing a dynamic theme switching feature on a web page using CSS variables and JavaScript. We'll create both dark and light themes and allow users to toggle between them seamlessly.&lt;/p&gt;

&lt;h2&gt;
  
  
  Prerequisites:
&lt;/h2&gt;

&lt;p&gt;Basic knowledge of HTML, CSS, and JavaScript.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 1: Setting Up the HTML Structure:
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="cp"&gt;&amp;lt;!DOCTYPE html&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;html&lt;/span&gt; &lt;span class="na"&gt;lang=&lt;/span&gt;&lt;span class="s"&gt;"en"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;

  &lt;span class="nt"&gt;&amp;lt;head&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;meta&lt;/span&gt; &lt;span class="na"&gt;charset=&lt;/span&gt;&lt;span class="s"&gt;"UTF-8"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;meta&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"viewport"&lt;/span&gt; &lt;span class="na"&gt;content=&lt;/span&gt;&lt;span class="s"&gt;"width=device-width, initial-scale=1.0"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;title&amp;gt;&lt;/span&gt;Dynamic Theme Switching&lt;span class="nt"&gt;&amp;lt;/title&amp;gt;&lt;/span&gt;

    &lt;span class="nt"&gt;&amp;lt;link&lt;/span&gt; &lt;span class="na"&gt;rel=&lt;/span&gt;&lt;span class="s"&gt;"stylesheet"&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"style.css"&lt;/span&gt; &lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/head&amp;gt;&lt;/span&gt;

  &lt;span class="nt"&gt;&amp;lt;body&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;header&amp;gt;&lt;/span&gt;
      &lt;span class="nt"&gt;&amp;lt;h1&amp;gt;&lt;/span&gt;Dynamic Theme Switching 🎨&lt;span class="nt"&gt;&amp;lt;/h1&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/header&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;"container"&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;"card"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;h2&amp;gt;&lt;/span&gt;Hello World! 👋&lt;span class="nt"&gt;&amp;lt;/h2&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;Welcome to our website. Enjoy the dynamic theme switching feature!&lt;span class="nt"&gt;&amp;lt;/p&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&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;"theme-toggle"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Toggle Theme 🌗&lt;span class="nt"&gt;&amp;lt;/button&amp;gt;&lt;/span&gt;

    &lt;span class="nt"&gt;&amp;lt;footer&amp;gt;&lt;/span&gt;
      &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;© 2024 Dynamic Theme Switching. All rights reserved.&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/footer&amp;gt;&lt;/span&gt;

    &lt;span class="nt"&gt;&amp;lt;script &lt;/span&gt;&lt;span class="na"&gt;src=&lt;/span&gt;&lt;span class="s"&gt;"script.js"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/script&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/body&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;/html&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 2: Creating the CSS Styles:
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="c"&gt;/* styles.css */&lt;/span&gt;

&lt;span class="nd"&gt;:root&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="py"&gt;--bg-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#ffffff&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="c"&gt;/* default light mode background color */&lt;/span&gt;
  &lt;span class="py"&gt;--text-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#000000&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="c"&gt;/* default light mode text color */&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.dark-mode&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="py"&gt;--bg-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#333333&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="py"&gt;--text-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#ffffff&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nt"&gt;body&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--bg-color&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="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--text-color&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;background-color&lt;/span&gt; &lt;span class="m"&gt;0.3s&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="n"&gt;color&lt;/span&gt; &lt;span class="m"&gt;0.3s&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="n"&gt;Arial&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;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="p"&gt;}&lt;/span&gt;

&lt;span class="nt"&gt;header&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--bg-color&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="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--text-color&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;20px&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="nl"&gt;border-bottom&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1px&lt;/span&gt; &lt;span class="nb"&gt;solid&lt;/span&gt; &lt;span class="nb"&gt;rgb&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;175&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;175&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;175&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.container&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;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;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;min-height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;60vh&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.card&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--light-bg-color&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;10px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;box-shadow&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;10px&lt;/span&gt; &lt;span class="n"&gt;rgba&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="m"&gt;0&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="m"&gt;0.1&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;20px&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="nt"&gt;button&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#007bff&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;#ffffff&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;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;20px&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;16px&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;5px&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="nl"&gt;transition&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;background-color&lt;/span&gt; &lt;span class="m"&gt;0.3s&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="p"&gt;}&lt;/span&gt;

&lt;span class="nt"&gt;button&lt;/span&gt;&lt;span class="nd"&gt;:hover&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#0056b3&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="nf"&gt;#theme-toggle&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;fixed&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;bottom&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;right&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-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#007bff&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;#ffffff&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;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;20px&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;16px&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;5px&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="nl"&gt;transition&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;background-color&lt;/span&gt; &lt;span class="m"&gt;0.3s&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="nf"&gt;#theme-toggle&lt;/span&gt;&lt;span class="nd"&gt;:hover&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#0056b3&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nt"&gt;footer&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;border-top&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1px&lt;/span&gt; &lt;span class="nb"&gt;solid&lt;/span&gt; &lt;span class="nb"&gt;rgb&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;175&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;175&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;175&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--bg-color&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="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--text-color&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;20px&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;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 3: Implementing the JavaScript Logic:
&lt;/h3&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;themeToggle&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="s1"&gt;theme-toggle&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;body&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="nx"&gt;body&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="nx"&gt;themeToggle&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;addEventListener&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;click&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="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;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="s1"&gt;dark-mode&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;h3&gt;
  
  
  Step 4: Testing and Final Touches:
&lt;/h3&gt;

&lt;p&gt;Open the HTML file in a browser.&lt;br&gt;
Click the "Toggle Theme" button to switch between dark and light modes.&lt;br&gt;
Make any additional adjustments to the CSS for better theme consistency.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion:
&lt;/h2&gt;

&lt;p&gt;Congratulations! You've successfully implemented a dynamic theme switching feature using CSS variables and JavaScript. Users can now enjoy a personalized browsing experience with dark and light modes.&lt;/p&gt;

</description>
      <category>html</category>
      <category>css</category>
      <category>var</category>
      <category>javascript</category>
    </item>
    <item>
      <title>You Don’t Need Redux — 3 Simple Alternatives for State Management in React 🚫🔄</title>
      <dc:creator>Muhammad Ayoub Khan</dc:creator>
      <pubDate>Sun, 12 Mar 2023 11:47:00 +0000</pubDate>
      <link>https://dev.to/ayoubkhan558/you-dont-need-redux-3-simple-alternatives-for-state-management-in-react-4038</link>
      <guid>https://dev.to/ayoubkhan558/you-dont-need-redux-3-simple-alternatives-for-state-management-in-react-4038</guid>
      <description>&lt;p&gt;When it comes to state management in React, Redux has been a popular choice for a long time. However, Redux can be complex and difficult to implement, especially for small and medium-sized projects. Fortunately, there are some simple alternatives to Redux that can handle state management effectively. In this article, we will discuss three simple alternatives to Redux for state management in React.&lt;/p&gt;

&lt;h2&gt;
  
  
  Introduction 🌟
&lt;/h2&gt;

&lt;p&gt;React is a popular front-end library for building user interfaces. React components need to manage state to display dynamic content and handle user interaction. Redux has been a go-to solution for state management in React for a long time, but it can be complex and difficult to implement. In this article, we will explore some simple alternatives to Redux that can handle state management effectively.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why Do We Need Alternatives to Redux? 🤔
&lt;/h3&gt;

&lt;p&gt;Redux is a powerful state management library that has been widely adopted in the React community. However, it has some drawbacks that make it difficult to use in certain scenarios. Some of the common issues with Redux are:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Steep learning curve&lt;/li&gt;
&lt;li&gt;Boilerplate code&lt;/li&gt;
&lt;li&gt;Complex setup&lt;/li&gt;
&lt;li&gt;Large codebase&lt;/li&gt;
&lt;li&gt;Too much ceremony for small projects
These issues make Redux a less than ideal choice for small and medium-sized projects. Fortunately, there are some simple alternatives that can handle state management effectively without the overhead of Redux.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  3 Simple Alternatives to Redux 🙌
&lt;/h2&gt;

&lt;h3&gt;
  
  
  React Context 🌳
&lt;/h3&gt;

&lt;p&gt;React Context is a built-in feature of React that provides a way to share data between components without the need for props drilling. It works by creating a context object that can be consumed by any component in the tree.&lt;/p&gt;

&lt;p&gt;React Context is a simple and lightweight solution for state management in React. It can handle small and medium-sized projects effectively without the overhead of Redux.&lt;br&gt;
&lt;a href="https://reactjs.org/docs/context.html" rel="noopener noreferrer"&gt;https://reactjs.org/docs/context.html&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Zustand 🏃‍♀️
&lt;/h3&gt;

&lt;p&gt;Zustand is a small, fast, and lightweight state management library for React. It provides a simple API for managing state and supports advanced features like derived state, middleware, and devtools.&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%2F3c9kg9hwr3tono4u8pp6.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%2F3c9kg9hwr3tono4u8pp6.png" alt=" " width="800" height="400"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Zustand is a great alternative to Redux for small and medium-sized projects. It provides a simple and intuitive API that can handle most state management requirements.&lt;br&gt;
&lt;a href="https://zustand-demo.pmnd.rs/" rel="noopener noreferrer"&gt;https://zustand-demo.pmnd.rs/&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Recoil 🎯
&lt;/h3&gt;

&lt;p&gt;Recoil is a state management library for React that provides a simple and intuitive API for managing state. It is built on top of React Hooks and supports advanced features like selectors, asynchronous state updates, and devtools.&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%2Freb4zb4f58ef5xpulznj.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%2Freb4zb4f58ef5xpulznj.png" alt=" " width="800" height="196"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Recoil is a great alternative to Redux for small and medium-sized projects. It provides a simple and intuitive API that can handle most state management requirements.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://recoiljs.org/" rel="noopener noreferrer"&gt;https://recoiljs.org/&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion 🌟
&lt;/h2&gt;

&lt;p&gt;Redux is a powerful state management library that has been widely adopted in the React community. However, it can be complex and difficult to implement, especially for small and medium-sized projects. Fortunately, there are some simple alternatives to Redux that can handle state management effectively. In this article, we discussed three simple alternatives to Redux: React Context, Zustand, and Recoil.&lt;/p&gt;

&lt;h2&gt;
  
  
  FAQs ❓
&lt;/h2&gt;

&lt;h3&gt;
  
  
  What is state management? 🤔
&lt;/h3&gt;

&lt;p&gt;State management is the process of managing the state of a web application. It involves storing and updating data that determines the behavior and appearance of the application.&lt;/p&gt;

&lt;h3&gt;
  
  
  What is Redux? 🔄
&lt;/h3&gt;

&lt;p&gt;Redux is a state management library for JavaScript applications. It provides a predictable and centralized way to manage state in large and complex applications.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why do we need state management in React? 🌟
&lt;/h3&gt;

&lt;p&gt;React components need to manage state to display dynamic content and handle user interaction.&lt;/p&gt;

&lt;h3&gt;
  
  
  What are the benefits of using alternatives to Redux? 🌟
&lt;/h3&gt;

&lt;p&gt;Alternatives to Redux can be simpler, faster, and easier to use than Redux&lt;/p&gt;

</description>
    </item>
    <item>
      <title>React vs Vue: The Core Similarities and Differences</title>
      <dc:creator>Muhammad Ayoub Khan</dc:creator>
      <pubDate>Sun, 26 Feb 2023 01:40:27 +0000</pubDate>
      <link>https://dev.to/ayoubkhan558/react-vs-vue-the-core-similarities-and-differences-a04</link>
      <guid>https://dev.to/ayoubkhan558/react-vs-vue-the-core-similarities-and-differences-a04</guid>
      <description>&lt;p&gt;Are you planning to build a new web application but confused about which JavaScript framework to choose? Two popular contenders in the market are React and Vue. Both React and Vue are highly capable JavaScript libraries that offer incredible flexibility, scalability, and robustness for building complex web applications. In this article, we will dive into React vs Vue: The Core Similarities and Differences, to help you choose the best one for your next project.&lt;/p&gt;

&lt;p&gt;SEO Meta Description: In this article, we will discuss the similarities and differences between two popular JavaScript frameworks, React and Vue, to help you choose the best one for your next web application project.&lt;/p&gt;

&lt;h2&gt;
  
  
  Introduction:
&lt;/h2&gt;

&lt;p&gt;React and Vue are two of the most popular JavaScript frameworks available today. React was developed by Facebook in 2011, whereas Vue was created by Evan You in 2014. Both React and Vue have their own set of features, benefits, and limitations. However, they share many similarities as well. React and Vue are both used for building interactive user interfaces, and they are popular among developers for their flexibility, performance, and ease of use.&lt;/p&gt;

&lt;h2&gt;
  
  
  React vs Vue: A Brief Overview
&lt;/h2&gt;

&lt;p&gt;React is a JavaScript library developed by Facebook for building complex user interfaces. It allows developers to create reusable UI components and manage state using a virtual DOM. React is highly performant and widely used by many large organizations, including Facebook, Airbnb, and Netflix.&lt;/p&gt;

&lt;p&gt;Vue, on the other hand, is a progressive JavaScript framework for building user interfaces. It emphasizes reusability and simplicity, and it is designed to be easy to learn and use. Vue is often compared to Angular and React, but it has its own unique set of features and benefits.&lt;/p&gt;

&lt;h2&gt;
  
  
  React vs Vue: Similarities and Differences
&lt;/h2&gt;

&lt;p&gt;React and Vue share many similarities, such as:&lt;/p&gt;

&lt;p&gt;Both use a virtual DOM to update the UI efficiently&lt;br&gt;
Both offer reactive and declarative programming models&lt;br&gt;
Both are lightweight and can be used with other libraries and frameworks&lt;br&gt;
Both provide excellent documentation and tooling support&lt;br&gt;
However, there are some key differences between React and Vue, such as:&lt;/p&gt;

&lt;p&gt;React is a library, whereas Vue is a full-blown framework&lt;br&gt;
React uses JSX for building UI components, while Vue uses templates and render functions&lt;br&gt;
React has a steeper learning curve than Vue due to its more complex architecture&lt;br&gt;
Vue offers built-in support for two-way data binding, while React requires additional libraries or manual implementation&lt;br&gt;
React vs Vue: Performance&lt;/p&gt;

&lt;p&gt;Performance is a crucial factor to consider when choosing a JavaScript framework for your project. React and Vue both offer excellent performance, but they have some differences.&lt;/p&gt;

&lt;h2&gt;
  
  
  React Performance:
&lt;/h2&gt;

&lt;p&gt;React's virtual DOM is highly optimized for performance, making it ideal for building large-scale, complex web applications. React also provides excellent server-side rendering support, which can improve initial page load times and SEO.&lt;/p&gt;

&lt;h2&gt;
  
  
  Vue Performance:
&lt;/h2&gt;

&lt;p&gt;Vue is also highly performant, and it has a smaller runtime size than React, which can improve load times. Vue's rendering engine is highly optimized, and it offers excellent support for lazy-loading and code splitting, which can further improve performance.&lt;/p&gt;

&lt;h2&gt;
  
  
  React vs Vue: Learning Curve
&lt;/h2&gt;

&lt;p&gt;Learning curve is another crucial factor to consider when choosing a JavaScript framework. React and Vue both have their own learning curves.&lt;br&gt;
React has a steeper learning curve due to its more complex architecture. React requires developers to learn JSX, which is a syntax extension to JavaScript that allows developers to write HTML-like code in their JavaScript files. React also has a larger ecosystem of tools and libraries, which can be overwhelming for beginners.&lt;/p&gt;

&lt;p&gt;Vue, on the other hand, has a gentler learning curve due to its simplicity and ease of use. Vue uses templates and render functions, which are similar to HTML and JavaScript, making it easier for developers to get started. Vue also provides excellent documentation and tooling support, which can help developers learn and use the framework more easily.&lt;/p&gt;

&lt;h2&gt;
  
  
  React vs Vue: Community Support
&lt;/h2&gt;

&lt;p&gt;Community support is another essential factor to consider when choosing a JavaScript framework. React and Vue both have active and growing communities, but there are some differences.&lt;/p&gt;

&lt;p&gt;React has a massive community of developers and organizations that use and contribute to the framework. React has been around for longer than Vue, which has helped it establish a strong community of contributors, tooling, and libraries. React also has excellent documentation, tooling, and support from Facebook, which makes it easier for developers to use and learn.&lt;/p&gt;

&lt;p&gt;Vue, on the other hand, has a smaller but growing community of developers and organizations that use and contribute to the framework. Vue has gained popularity in recent years due to its simplicity and ease of use, which has helped it attract more developers and organizations. Vue also has excellent documentation, tooling, and support from the Vue team, which makes it easier for developers to use and learn.&lt;/p&gt;

&lt;h2&gt;
  
  
  React vs Vue: Popularity and Job Market
&lt;/h2&gt;

&lt;p&gt;Popularity and job market are two factors that can impact your decision when choosing a JavaScript framework. React and Vue both have high popularity and job demand, but there are some differences.&lt;/p&gt;

&lt;p&gt;React is currently the most popular JavaScript library, according to the 2021 Stack Overflow Developer Survey. React has a massive user base and job demand, with many large organizations using and hiring React developers. React is also used in many high-traffic websites and applications, making it a safe and reliable choice for building complex web applications.&lt;/p&gt;

&lt;p&gt;Vue, on the other hand, is also gaining popularity and job demand, according to the same survey. Vue has a growing user base and job demand, with many startups and small to medium-sized organizations using and hiring Vue developers. Vue is also known for its ease of use and flexibility, making it a popular choice for building simple to medium complexity web applications.&lt;/p&gt;

&lt;h2&gt;
  
  
  React vs Vue: Which One to Choose for Your Project?
&lt;/h2&gt;

&lt;p&gt;Choosing between React and Vue ultimately depends on your project's requirements, team's expertise, and personal preferences. If you're building a large-scale, complex web application with a steep learning curve, React may be the better choice. If you're building a small to medium-sized web application with a simpler architecture and an easier learning curve, Vue may be the better choice.&lt;/p&gt;

&lt;p&gt;Regardless of which framework you choose, both React and Vue offer excellent performance, flexibility, and community support. With the right team and tools, you can build robust and scalable web applications with either framework.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>fullstack</category>
      <category>php</category>
      <category>react</category>
    </item>
    <item>
      <title>🔄🔂 5 Simple Ways to Loop Over Data in HTML Using JavaScript 📊📝</title>
      <dc:creator>Muhammad Ayoub Khan</dc:creator>
      <pubDate>Fri, 24 Feb 2023 12:48:00 +0000</pubDate>
      <link>https://dev.to/ayoubkhan558/5-simple-ways-to-loop-over-data-in-html-using-javascript-30kb</link>
      <guid>https://dev.to/ayoubkhan558/5-simple-ways-to-loop-over-data-in-html-using-javascript-30kb</guid>
      <description>&lt;p&gt;Looping over data is a common task when working with web applications. Whether you're displaying data in a table, a list, or any other format, you'll often need to loop through an array or object to generate the corresponding HTML markup. In this article, we'll explore five different ways to loop over data in HTML using JavaScript.&lt;/p&gt;

&lt;h2&gt;
  
  
  The for Loop
&lt;/h2&gt;

&lt;p&gt;The for loop is the most common and versatile way to loop over an array in JavaScript. Here's an example:&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;data&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;apple&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;banana&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;cherry&lt;/span&gt;&lt;span class="dl"&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;let&lt;/span&gt; &lt;span class="nx"&gt;i&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;i&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&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;length&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&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="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;listItem&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;createElement&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;li&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nx"&gt;listItem&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;data&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="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="s1"&gt;ul&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;appendChild&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;listItem&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;In this example, we're using a for loop to iterate over an array of fruits and create a new list item element for each one.&lt;/p&gt;

&lt;h2&gt;
  
  
  The forEach Method
&lt;/h2&gt;

&lt;p&gt;The forEach method is a built-in function of arrays that allows you to loop through each element and perform an action on it. Here's an example:&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;data&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;apple&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;banana&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;cherry&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;span class="nf"&gt;forEach&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="nx"&gt;item&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="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;listItem&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;createElement&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;li&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nx"&gt;listItem&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;item&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;querySelector&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;ul&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;appendChild&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;listItem&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;In this example, we're using the forEach method to iterate over the array and create a new list item element for each element.&lt;/p&gt;

&lt;h2&gt;
  
  
  The for...in Loop
&lt;/h2&gt;

&lt;p&gt;The for...in loop is a built-in JavaScript loop that allows you to loop over the keys of an object. Here's an example:&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;data&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;John&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;age&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="na"&gt;city&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;New York&lt;/span&gt;&lt;span class="dl"&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;let&lt;/span&gt; &lt;span class="nx"&gt;key&lt;/span&gt; &lt;span class="k"&gt;in&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="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;listItem&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;createElement&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;li&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nx"&gt;listItem&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="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;key&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;data&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;key&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="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="s1"&gt;ul&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;appendChild&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;listItem&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;In this example, we're using the for...in loop to loop over the keys of an object and create a new list item element for each key-value pair.&lt;/p&gt;

&lt;h2&gt;
  
  
  The for...of Loop
&lt;/h2&gt;

&lt;p&gt;The for...of loop is a built-in JavaScript loop that allows you to loop over the values of an iterable object, such as an array. Here's an example:&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;data&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;apple&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;banana&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;cherry&lt;/span&gt;&lt;span class="dl"&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;let&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;data&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;listItem&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;createElement&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;li&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nx"&gt;listItem&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;item&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;querySelector&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;ul&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;appendChild&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;listItem&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;In this example, we're using the for...of loop to loop over the values of an array and create a new list item element for each element.&lt;/p&gt;

&lt;h2&gt;
  
  
  The map Method
&lt;/h2&gt;

&lt;p&gt;The map method is another built-in function of arrays that allows you to loop through each element and create a new array with the results. Here's an example:&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;data&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;apple&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;banana&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;cherry&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;listItems&lt;/span&gt; &lt;span class="o"&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;map&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="nx"&gt;item&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="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;listItem&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;createElement&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;li&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nx"&gt;listItem&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;item&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;listItem&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;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&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="s1"&gt;ul&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;append&lt;/span&gt;&lt;span class="p"&gt;(...&lt;/span&gt;&lt;span class="nx"&gt;listItems&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In this example, we're using the map method to iterate over the array and create a new list item element for each element. We're then using the spread operator to append all of the list items to the unordered list element.&lt;/p&gt;

&lt;p&gt;These are just a few of the many ways to loop over data in HTML using JavaScript. By understanding these techniques, you can write more efficient and maintainable code when working with web applications.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>html</category>
      <category>javascript</category>
      <category>programming</category>
    </item>
    <item>
      <title>7 best ReactJS developer tools to simplify your workflow</title>
      <dc:creator>Muhammad Ayoub Khan</dc:creator>
      <pubDate>Thu, 23 Feb 2023 19:59:00 +0000</pubDate>
      <link>https://dev.to/ayoubkhan558/7-best-reactjs-developer-tools-to-simplify-your-workflow-5fec</link>
      <guid>https://dev.to/ayoubkhan558/7-best-reactjs-developer-tools-to-simplify-your-workflow-5fec</guid>
      <description>&lt;p&gt;ReactJS is a popular JavaScript library used for building web applications. Its flexibility and reusability make it a favorite among developers. However, the development process can be time-consuming and challenging, especially when working on large and complex projects. Luckily, there are many ReactJS developer tools available to simplify the workflow and make development faster and more efficient.&lt;/p&gt;

&lt;p&gt;Here are the 7 best ReactJS developer tools that can help you to streamline your development process:&lt;/p&gt;

&lt;h2&gt;
  
  
  React Developer Tools
&lt;/h2&gt;

&lt;p&gt;React Developer Tools is a browser extension that allows developers to inspect React components and their structure. This tool provides an easy way to debug and troubleshoot React applications. You can download it from its official GitHub repository: &lt;br&gt;
&lt;a href="https://chrome.google.com/webstore/detail/react-developer-tools/fmkadmapgofadopljbjfkapdkoienihi?hl=en" rel="noopener noreferrer"&gt;https://chrome.google.com/webstore/detail/react-developer-tools/fmkadmapgofadopljbjfkapdkoienihi?hl=en&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Redux DevTools
&lt;/h2&gt;

&lt;p&gt;Redux DevTools is a browser extension that allows developers to inspect and debug Redux stores. This tool helps developers to track state changes, actions, and other data related to the Redux store. You can download it from its official GitHub repository: &lt;a href="https://chrome.google.com/webstore/detail/redux-devtools/lmhkpmbekcpmknklioeibfkpmmfibljd?hl=en" rel="noopener noreferrer"&gt;https://chrome.google.com/webstore/detail/redux-devtools/lmhkpmbekcpmknklioeibfkpmmfibljd?hl=en&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Bit
&lt;/h2&gt;

&lt;p&gt;Bit is a tool that helps developers to share and reuse React components across projects. It allows developers to create and manage a shared component library, making it easier to maintain consistency and improve productivity. You can visit its official website to learn more: &lt;br&gt;
&lt;a href="https://bit.dev/" rel="noopener noreferrer"&gt;https://bit.dev/&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Storybook
&lt;/h2&gt;

&lt;p&gt;Storybook is a tool that allows developers to build and test React components in isolation. This tool provides a visual interface for creating and testing components, making it easier to develop and debug UI components. You can visit its official website to learn more: &lt;a href="https://storybook.js.org/" rel="noopener noreferrer"&gt;https://storybook.js.org/&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  React Styleguidist
&lt;/h2&gt;

&lt;p&gt;React Styleguidist is a tool that generates a living style guide for React components. This tool helps developers to document and showcase their components, making it easier for other developers to understand and use them. You can visit its official website to learn more: &lt;br&gt;
&lt;a href="https://react-styleguidist.js.org/" rel="noopener noreferrer"&gt;https://react-styleguidist.js.org/&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  ESLint
&lt;/h2&gt;

&lt;p&gt;ESLint is a tool that helps developers to identify and fix common coding errors and maintain consistency in their code. It provides a set of rules and guidelines that can be customized to fit the specific needs of a project. You can visit its official website to learn more: &lt;br&gt;
&lt;a href="https://eslint.org" rel="noopener noreferrer"&gt;https://eslint.org&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Prettier
&lt;/h2&gt;

&lt;p&gt;Prettier is a code formatter that helps developers to maintain consistent code formatting across a project. It automatically formats code based on a set of rules, making it easier to read and understand. You can visit its official website to learn more: &lt;br&gt;
&lt;a href="https://prettier.io/" rel="noopener noreferrer"&gt;https://prettier.io/&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;These 7 ReactJS developer tools can help streamline the development process and improve productivity. React Developer Tools, Redux DevTools, Bit, Storybook, React Styleguidist, ESLint, and Prettier are all excellent tools that can simplify your workflow and make your ReactJS development experience more efficient and enjoyable. Give them a try and see how they can help you to simplify your workflow!&lt;/p&gt;

</description>
      <category>react</category>
      <category>javascript</category>
      <category>tools</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Top Chrome Extensions Every Frontend Developer Should Use 💡💻🔧</title>
      <dc:creator>Muhammad Ayoub Khan</dc:creator>
      <pubDate>Wed, 22 Feb 2023 19:53:23 +0000</pubDate>
      <link>https://dev.to/ayoubkhan558/top-chrome-extensions-every-frontend-developer-should-use-96o</link>
      <guid>https://dev.to/ayoubkhan558/top-chrome-extensions-every-frontend-developer-should-use-96o</guid>
      <description>&lt;p&gt;Introduction: As a frontend developer, using the right tools is essential for improving productivity and delivering high-quality work. Chrome extensions can be incredibly helpful in this regard, providing a range of features that can streamline your workflow, optimize your code, and improve your overall development experience. In this thread, we've highlighted some of the best Chrome extensions for frontend developers, which can help you build better websites and applications faster and more efficiently.&lt;/p&gt;

&lt;h1&gt;
  
  
  1. Lighthouse
&lt;/h1&gt;

&lt;p&gt;Audits your web pages for performance, accessibility, and best practices. 💻🚀 Get it from &lt;a href="https://chrome.google.com/webstore/detail/lighthouse/blipmdconlkpinefehnmjammfjpmpbjk" rel="noopener noreferrer"&gt;https://chrome.google.com/webstore/detail/lighthouse/blipmdconlkpinefehnmjammfjpmpbjk&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  2. JSON Viewer
&lt;/h1&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%2F8ygslvbzlyl7d22i8k6p.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%2F8ygslvbzlyl7d22i8k6p.png" alt=" " width="128" height="128"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Makes JSON data easier to read and debug by formatting it in a tree structure. 🔍💡 Get it from &lt;a href="https://chrome.google.com/webstore/detail/json-viewer/gbmdgpbipfallnflgajpaliibnhdgobh" rel="noopener noreferrer"&gt;https://chrome.google.com/webstore/detail/json-viewer/gbmdgpbipfallnflgajpaliibnhdgobh&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  3. React Developer Tools
&lt;/h1&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%2F8efcvalweh9u8vyio75f.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%2F8efcvalweh9u8vyio75f.png" alt=" " width="128" height="128"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Allows you to inspect the React component hierarchy and see their props, state, and more. 🔍💡 Get it from &lt;a href="https://chrome.google.com/webstore/detail/react-developer-tools/fmkadmapgofadopljbjfkapdkoienihi" rel="noopener noreferrer"&gt;https://chrome.google.com/webstore/detail/react-developer-tools/fmkadmapgofadopljbjfkapdkoienihi&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  4. Axios Dev Tools
&lt;/h1&gt;

&lt;p&gt;Makes it easy to debug Axios API requests and responses. 🔧💻 Get it from &lt;a href="https://chrome.google.com/webstore/detail/axios-dev-tools/cffnfgppjihohebhicijihlhnpkpjifd" rel="noopener noreferrer"&gt;https://chrome.google.com/webstore/detail/axios-dev-tools/cffnfgppjihohebhicijihlhnpkpjifd&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  5. CSS Peeper
&lt;/h1&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%2Fvfg2ovli3wfg2y7v5485.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%2Fvfg2ovli3wfg2y7v5485.png" alt=" " width="128" height="128"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Inspect and copy any CSS styles from a website with just one click. 🔍🎨 Get it from &lt;a href="https://chrome.google.com/webstore/detail/css-peeper/mbnbehikldjhnfehhnaidhjhoofhpehk" rel="noopener noreferrer"&gt;https://chrome.google.com/webstore/detail/css-peeper/mbnbehikldjhnfehhnaidhjhoofhpehk&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  6. Fontface Ninja
&lt;/h1&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%2Fp9yqaac6dh30ma7ws59d.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%2Fp9yqaac6dh30ma7ws59d.png" alt=" " width="128" height="128"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Allows you to identify the fonts used on any website with ease. 🔍🎨 Get it from &lt;a href="https://chrome.google.com/webstore/detail/fonts-ninja/eljapbgkmlngdpckoiiibecpemleclhh" rel="noopener noreferrer"&gt;https://chrome.google.com/webstore/detail/fonts-ninja/eljapbgkmlngdpckoiiibecpemleclhh&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  8. Wappalyzer
&lt;/h1&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%2Fbmxe3edvym503uvrcx2t.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%2Fbmxe3edvym503uvrcx2t.png" alt=" " width="128" height="128"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Reveals the technologies used on a website, including the CMS, e-commerce platform, and more. 🔍💻 Get it from &lt;a href="https://chrome.google.com/webstore/detail/wappalyzer/gppongmhjkpfnbhagpmjfkannfbllamg" rel="noopener noreferrer"&gt;https://chrome.google.com/webstore/detail/wappalyzer/gppongmhjkpfnbhagpmjfkannfbllamg&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;These are just a few of the best #ChromeExtensions for frontend development. Which ones do you use and love? 💻🔧 #WebDevelopment #FrontendTools 💻🔧&lt;/p&gt;

</description>
    </item>
    <item>
      <title>7 Killer 🗡 JS techniques 🔥you've probably never heard of 🔈</title>
      <dc:creator>Muhammad Ayoub Khan</dc:creator>
      <pubDate>Wed, 22 Feb 2023 19:33:38 +0000</pubDate>
      <link>https://dev.to/ayoubkhan558/7-killer-js-techniques-youve-probably-never-heard-of-l1p</link>
      <guid>https://dev.to/ayoubkhan558/7-killer-js-techniques-youve-probably-never-heard-of-l1p</guid>
      <description>&lt;p&gt;JavaScript is a powerful and versatile programming language that is constantly evolving. With new frameworks, libraries, and tools being released every year, it's easy to overlook some of the lesser-known but incredibly useful techniques and features that JavaScript has to offer. In this article, we'll explore 7 killer JavaScript techniques that you've probably never heard of. These techniques will help you to write more efficient, elegant, and maintainable code, and take your JavaScript skills to the next level. So, let's dive in!&lt;/p&gt;

&lt;h2&gt;
  
  
  Memoization
&lt;/h2&gt;

&lt;p&gt;Memoization is a technique that involves caching the results of expensive function calls and returning the cached results when the same inputs occur again. This technique can significantly improve the performance of your JavaScript code, especially when dealing with complex and time-consuming calculations.&lt;br&gt;
Here is an example of a memoized function that calculates the nth Fibonacci number:&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;memoize&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;func&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;cache&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{};&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;(...&lt;/span&gt;&lt;span class="nx"&gt;args&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;key&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;JSON&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;stringify&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;args&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;cache&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;key&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;cache&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;key&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;result&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;func&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;apply&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;args&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="nx"&gt;cache&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nx"&gt;key&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;result&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;result&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="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;fibonacci&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;memoize&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;n&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;n&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="nx"&gt;n&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;n&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="nf"&gt;fibonacci&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;n&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="o"&gt;+&lt;/span&gt; &lt;span class="nf"&gt;fibonacci&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;n&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="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="nf"&gt;fibonacci&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="c1"&gt;// 55&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="nf"&gt;fibonacci&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;20&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt; &lt;span class="c1"&gt;// 6765&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Currying
&lt;/h2&gt;

&lt;p&gt;Currying is a functional programming technique that involves transforming a function with multiple arguments into a sequence of functions, each with a single argument. This technique can make your code more modular and reusable, and it's particularly useful for creating higher-order functions that can be composed together.&lt;br&gt;
Here is an example of a curried function that adds two numbers:&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;add&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="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nf"&gt;function &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="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;a&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nx"&gt;b&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="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;add5&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;add&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="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="nf"&gt;add5&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="c1"&gt;// 15&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Throttling
&lt;/h2&gt;

&lt;p&gt;Throttling is a technique that limits the rate at which a function can be called. This technique can prevent performance issues caused by rapid and repeated function calls, such as when handling user input or making API requests.&lt;br&gt;
Here is an example of a throttled function that logs a message every 1000 milliseconds:&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;throttle&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;func&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;delay&lt;/span&gt;&lt;span class="p"&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;last&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;return&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;(...&lt;/span&gt;&lt;span class="nx"&gt;args&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;now&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;Date&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="nf"&gt;getTime&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;now&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="nx"&gt;last&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;delay&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="p"&gt;;&lt;/span&gt;
    &lt;span class="p"&gt;}&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;now&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nx"&gt;func&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;apply&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;args&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="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;logMessage&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;message&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;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;message&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;throttledLogMessage&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;throttle&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;logMessage&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="nf"&gt;throttledLogMessage&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Hello&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="c1"&gt;// logs "Hello"&lt;/span&gt;
&lt;span class="nf"&gt;throttledLogMessage&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;World&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="c1"&gt;// does not log&lt;/span&gt;
&lt;span class="nf"&gt;setTimeout&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nf"&gt;throttledLogMessage&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Goodbye&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="c1"&gt;// logs "Goodbye"&lt;/span&gt;
&lt;span class="p"&gt;},&lt;/span&gt; &lt;span class="mi"&gt;2000&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Debouncing
&lt;/h2&gt;

&lt;p&gt;Debouncing is a technique that delays the execution of a function until a certain amount of time has passed without any further function calls. This technique can be useful for handling events that occur frequently, such as scroll or resize events, and can help to prevent performance issues caused by excessive function calls.&lt;br&gt;
Here is an example of a debounced function that logs a message 500 milliseconds after the last function call:&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;debounce&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;func&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;delay&lt;/span&gt;&lt;span class="p"&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;timeout&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;(...&lt;/span&gt;&lt;span class="nx"&gt;args&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nf"&gt;clearTimeout&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;timeout&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="nx"&gt;timeout&lt;/span&gt; &lt;span class="o"&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="p"&gt;{&lt;/span&gt;
      &lt;span class="nx"&gt;func&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;apply&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;args&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="p"&gt;},&lt;/span&gt; &lt;span class="nx"&gt;delay&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="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;logMessage&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;message&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;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;message&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;debouncedLogMessage&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;debounce&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;logMessage&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;span class="nf"&gt;debouncedLogMessage&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Hello&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="c1"&gt;// does not log&lt;/span&gt;
&lt;span class="nf"&gt;debouncedLogMessage&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;World&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="c1"&gt;// does not log&lt;/span&gt;
&lt;span class="nf"&gt;setTimeout&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nf"&gt;debouncedLogMessage&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Goodbye&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="c1"&gt;// logs "Goodbye"&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;h2&gt;
  
  
  Partial Application
&lt;/h2&gt;

&lt;p&gt;Partial application is a technique that involves fixing some of the arguments of a function, and returning a new function that takes the remaining arguments. This technique can be useful for creating new functions that are specialized for a particular use case, or for reducing the number of arguments that need to be passed to a function.&lt;br&gt;
Here is an example of a partially applied function that multiplies two numbers:&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;multiply&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="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;a&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="nx"&gt;b&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;double&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;multiply&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;bind&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kc"&gt;null&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="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="nf"&gt;double&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="c1"&gt;// 10&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Thanks for reading ✨!&lt;/p&gt;

&lt;p&gt;These 7 JavaScript techniques are just a small sampling of the many powerful tools and concepts available to developers. By using them in your own code, you can simplify complex operations, reduce code duplication, and improve the performance of your applications. Whether you're a seasoned JavaScript developer or just starting out, it's always a good idea to keep learning and exploring new techniques to take your coding skills to the next level. So go forth and experiment with these techniques, and see what else you can discover in the exciting and constantly evolving world of JavaScript development.&lt;/p&gt;

</description>
      <category>welcome</category>
    </item>
    <item>
      <title>Top 10 Class-Based UI Libraries for Frontend Web Development in 2023: A Comprehensive Guide</title>
      <dc:creator>Muhammad Ayoub Khan</dc:creator>
      <pubDate>Wed, 22 Feb 2023 19:09:56 +0000</pubDate>
      <link>https://dev.to/ayoubkhan558/top-10-class-based-ui-libraries-for-frontend-web-development-in-2023-a-comprehensive-guide-3ic1</link>
      <guid>https://dev.to/ayoubkhan558/top-10-class-based-ui-libraries-for-frontend-web-development-in-2023-a-comprehensive-guide-3ic1</guid>
      <description>&lt;p&gt;There are many class-based UI libraries available for frontend web development, each with its own unique features and advantages. Material UI, Semantic UI, Ant Design, Blueprint, Chakra UI, Carbon Design System, Grommet, Element, Shards React, and Rebass are just some of the popular UI libraries available for developers to use. These libraries offer a range of customizable components such as buttons, forms, and icons, along with responsive grid systems and customizable themes, making it easier for developers to create intuitive and visually appealing user interfaces. When choosing a UI library, it's important to consider factors such as ease of use, compatibility with your chosen front-end framework, and the specific needs of your project. With so many options available, developers can choose a library that meets their unique requirements and helps them to build high-quality user interfaces quickly and efficiently.&lt;/p&gt;

&lt;h2&gt;
  
  
  Material UI
&lt;/h2&gt;

&lt;p&gt;Material UI (&lt;a href="https://material-ui.com/):" rel="noopener noreferrer"&gt;https://material-ui.com/):&lt;/a&gt; Material UI is a popular UI library that follows the Material Design guidelines and provides a wide range of customizable UI components. It is built using React and offers themes, icons, and utilities to help developers quickly build responsive and intuitive user interfaces.&lt;/p&gt;

&lt;h2&gt;
  
  
  Semantic UI
&lt;/h2&gt;

&lt;p&gt;Semantic UI (&lt;a href="https://semantic-ui.com/):" rel="noopener noreferrer"&gt;https://semantic-ui.com/):&lt;/a&gt; Semantic UI is a user-friendly and intuitive UI library that focuses on human-friendly HTML and provides a variety of UI components, themes, and responsive layout options. It is built using HTML, CSS, and JavaScript and is compatible with many popular front-end frameworks such as React, Angular, and Vue.&lt;/p&gt;

&lt;h2&gt;
  
  
  Ant Design
&lt;/h2&gt;

&lt;p&gt;Ant Design (&lt;a href="https://ant.design/):" rel="noopener noreferrer"&gt;https://ant.design/):&lt;/a&gt; Ant Design is a comprehensive UI library that provides a range of high-quality React components with a consistent design language. It offers a wide range of UI components such as forms, tables, and charts, along with a flexible layout system and a customizable theme.&lt;/p&gt;

&lt;h2&gt;
  
  
  Blueprint
&lt;/h2&gt;

&lt;p&gt;Blueprint (&lt;a href="https://blueprintjs.com/):" rel="noopener noreferrer"&gt;https://blueprintjs.com/):&lt;/a&gt; Blueprint is a UI toolkit that provides a set of reusable UI components for building complex web applications. It is built using React and offers a range of customizable components such as buttons, forms, and modals, along with a responsive grid system and a flexible layout engine.&lt;/p&gt;

&lt;h2&gt;
  
  
  Chakra UI
&lt;/h2&gt;

&lt;p&gt;Chakra UI (&lt;a href="https://chakra-ui.com/):" rel="noopener noreferrer"&gt;https://chakra-ui.com/):&lt;/a&gt; Chakra UI is a simple, modular, and accessible UI library that provides a range of UI components and design systems. It is built using React and offers a wide range of customizable components such as buttons, inputs, and alerts, along with a responsive layout system and a customizable theme.&lt;/p&gt;

&lt;h2&gt;
  
  
  Carbon Design System
&lt;/h2&gt;

&lt;p&gt;Carbon Design System (&lt;a href="https://www.carbondesignsystem.com/):" rel="noopener noreferrer"&gt;https://www.carbondesignsystem.com/):&lt;/a&gt; Carbon Design System is a UI library that provides a set of reusable UI components with a consistent design system, suitable for building complex web applications. It is built using React and offers a wide range of customizable components such as buttons, inputs, and icons, along with a responsive layout system and a customizable theme.&lt;/p&gt;

&lt;h2&gt;
  
  
  Grommet
&lt;/h2&gt;

&lt;p&gt;Grommet (&lt;a href="https://grommet.io/):" rel="noopener noreferrer"&gt;https://grommet.io/):&lt;/a&gt; Grommet is a comprehensive UI library that provides a range of customizable UI components, layouts, and themes, suitable for building responsive web applications. It is built using React and offers a wide range of customizable components such as buttons, forms, and icons, along with a responsive grid system and a customizable theme.&lt;br&gt;
Element (&lt;a href="https://element.eleme.io/):" rel="noopener noreferrer"&gt;https://element.eleme.io/):&lt;/a&gt; Element is a UI library that provides a set of customizable UI components with a modern design and a responsive layout system. It is built using Vue.js and offers a wide range of customizable components such as buttons, inputs, and icons, along with a responsive grid system and a customizable theme.&lt;/p&gt;

&lt;h2&gt;
  
  
  Shards React
&lt;/h2&gt;

&lt;p&gt;Shards React (&lt;a href="https://designrevision.com/downloads/shards-react/):" rel="noopener noreferrer"&gt;https://designrevision.com/downloads/shards-react/):&lt;/a&gt; Shards React is a lightweight and modern UI library that provides a set of customizable UI components with a minimalist design. It is built using React and offers a wide range of customizable components such as buttons, inputs, and icons, along with a responsive grid system and a customizable theme.&lt;/p&gt;

&lt;h2&gt;
  
  
  Rebass
&lt;/h2&gt;

&lt;p&gt;Rebass (&lt;a href="https://rebassjs.org/):" rel="noopener noreferrer"&gt;https://rebassjs.org/):&lt;/a&gt; Rebass is a responsive UI library that provides a set of customizable UI components with a functional design language. It is built using React and offers a range of customizable components such as buttons, forms, and cards, along with a responsive grid system and a customizable theme.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;Class-based UI libraries are a useful tool for frontend web developers. They provide a range of customizable UI components, making it easier for developers to build intuitive and visually appealing user interfaces. With so many options available, developers can choose a library that meets their specific needs and helps them to create high-quality web applications.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Answer: How to add class to link in wp_nav_menu?</title>
      <dc:creator>Muhammad Ayoub Khan</dc:creator>
      <pubDate>Sun, 06 Jun 2021 13:39:49 +0000</pubDate>
      <link>https://dev.to/ayoubkhan558/answer-how-to-add-class-to-link-in-wpnavmenu-1hgp</link>
      <guid>https://dev.to/ayoubkhan558/answer-how-to-add-class-to-link-in-wpnavmenu-1hgp</guid>
      <description>&lt;div class="ltag__stackexchange--container"&gt;
  &lt;div class="ltag__stackexchange--title-container"&gt;
    
      &lt;div class="ltag__stackexchange--title"&gt;
        &lt;div class="ltag__stackexchange--header"&gt;
          &lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fassets.dev.to%2Fassets%2Fstackoverflow-logo-b42691ae545e4810b105ee957979a853a696085e67e43ee14c5699cf3e890fb4.svg" alt=""&gt;
          &lt;a href="https://stackoverflow.com/questions/26180688/how-to-add-class-to-link-in-wp-nav-menu/67859550#67859550" rel="noopener noreferrer"&gt;
            &lt;span class="title-flare"&gt;answer&lt;/span&gt; re: How to add class to link in wp_nav_menu?
          &lt;/a&gt;
        &lt;/div&gt;
        &lt;div class="ltag__stackexchange--post-metadata"&gt;
          &lt;span&gt;Jun  6 '21&lt;/span&gt;
        &lt;/div&gt;
      &lt;/div&gt;
      &lt;a class="ltag__stackexchange--score-container" href="https://stackoverflow.com/questions/26180688/how-to-add-class-to-link-in-wp-nav-menu/67859550#67859550" rel="noopener noreferrer"&gt;
        &lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fassets.dev.to%2Fassets%2Fstackexchange-arrow-up-eff2e2849e67d156181d258e38802c0b57fa011f74164a7f97675ca3b6ab756b.svg" alt=""&gt;
        &lt;div class="ltag__stackexchange--score-number"&gt;
          6
        &lt;/div&gt;
        &lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fassets.dev.to%2Fassets%2Fstackexchange-arrow-down-4349fac0dd932d284fab7e4dd9846f19a3710558efde0d2dfd05897f3eeb9aba.svg" alt=""&gt;
      &lt;/a&gt;
    
  &lt;/div&gt;
  &lt;div class="ltag__stackexchange--body"&gt;
    
&lt;p&gt;I have solution to add class to anchor tag.&lt;/p&gt;
&lt;p&gt;1: Step: add this in functions.php&lt;/p&gt;
&lt;pre class="lang-php prettyprint-override"&gt;&lt;code&gt;function add_additional_class_on_a($classes, $item, $args)
{
    if (isset($args-&amp;gt;add_a_class)) {
        $classes['class'] = $args-&amp;gt;add_a_class
    }
    return $classes;
}

add_filter('nav_menu_link_attributes', 'add_additional_class_on_a', 1, 3);
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;2: Then use it like this in your theme&lt;/p&gt;
&lt;pre class="lang-php prettyprint-override"&gt;&lt;code&gt;&amp;lt;?php
        // Show Menu here
        wp_nav_menu(array(
            'theme_location'&lt;/code&gt;&lt;/pre&gt;…
    
  &lt;/div&gt;
  &lt;div class="ltag__stackexchange--btn--container"&gt;
    &lt;a href="https://stackoverflow.com/questions/26180688/how-to-add-class-to-link-in-wp-nav-menu/67859550#67859550" class="ltag__stackexchange--btn" rel="noopener noreferrer"&gt;Open Full Answer&lt;/a&gt;
  &lt;/div&gt;
&lt;/div&gt;


</description>
    </item>
  </channel>
</rss>
