<?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: Ali Hussein</title>
    <description>The latest articles on DEV Community by Ali Hussein (@alihusseindev).</description>
    <link>https://dev.to/alihusseindev</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%2F561717%2F994b7813-6edf-4194-8bf3-ff32fae35ee8.jpeg</url>
      <title>DEV Community: Ali Hussein</title>
      <link>https://dev.to/alihusseindev</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/alihusseindev"/>
    <language>en</language>
    <item>
      <title>The New Way to Discover shadcn Blocks</title>
      <dc:creator>Ali Hussein</dc:creator>
      <pubDate>Sun, 29 Mar 2026 10:53:16 +0000</pubDate>
      <link>https://dev.to/alihusseindev/the-new-way-to-discover-shadcn-blocks-4c87</link>
      <guid>https://dev.to/alihusseindev/the-new-way-to-discover-shadcn-blocks-4c87</guid>
      <description>&lt;p&gt;Choosing the right component for a project used to be a five-minute task. Today, in the sprawling “shadcn ecosystem” of 2026, it can easily turn into an hour of tab-switching and repository hunting.&lt;/p&gt;

&lt;p&gt;The way we discover shadcn blocks has fundamentally changed. We’ve moved away from a single source of truth toward a decentralized world of registries and with that shift, we’ve needed a better way to navigate.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Paradox of Choice
&lt;/h2&gt;

&lt;p&gt;When shadcn/ui first dropped, it was a contained library. You went to the official site, found the Accordion or Button, and ran the CLI command.&lt;/p&gt;

&lt;p&gt;But shadcn wasn’t just a library; it was a movement. It encouraged developers to “own their code,” which led to an explosion of community-driven registries. Now, we have specialized blocks for everything: glassmorphism, AI chat interfaces, brutalist marketing sections, and complex data dashboards.&lt;/p&gt;

&lt;p&gt;The problem? They are all in different places.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Traditional Hunt (The Old Way)
&lt;/h2&gt;

&lt;p&gt;Before recently, the “old way” of finding a specific block felt like a digital scavenger hunt.&lt;/p&gt;

&lt;p&gt;You’d start at the official docs. If the look wasn’t quite right, you’d move to GitHub, searching through “Awesome shadcn” lists or scrolling through the shadcn-ui/ui commit history to find blocks that were deprecated or moved.&lt;/p&gt;

&lt;p&gt;Your browser would inevitably end up with 15 tabs open: one for Magic UI, one for Aceternity, another for a random indie registry you saw on X (Twitter). You’d spend twenty minutes just trying to see if a “Pricing Section” from one library would visually clash with a “Hero” from another. You weren’t building; you were auditing.&lt;/p&gt;

&lt;h2&gt;
  
  
  Centralizing the Ecosystem (The New Way)
&lt;/h2&gt;

&lt;p&gt;The shift in 2026 has been toward search aggregation. Instead of visiting every individual registry, developers are moving to &lt;a href="https://shoogle.dev" rel="noopener noreferrer"&gt;Shoogle.dev&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Think of it as a search engine built specifically for the shadcn era. Rather than replacement, it offers a unified interface for over 130 different registries.&lt;/p&gt;

&lt;p&gt;When you search for “AI Chat Container” or “Bento Grid,” Shoogle doesn’t just give you a link to a repo. It pulls results from across the entire ecosystem Retro UI, Blocks MVP, various specialized admin kits and presents them in a single, scannable feed.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why the Workflow Sticks
&lt;/h2&gt;

&lt;p&gt;The reason this has become the “new way” isn’t just about search; it’s about the friction it removes:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Integrated Previews&lt;/strong&gt;: You can evaluate the UI without leaving the search page. This kills the “tab-overload” cycle instantly.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Discovery of Niche Registries&lt;/strong&gt;: There are incredible developers building high-quality blocks who don’t have the SEO of the “big” libraries. Shoogle indexes these hidden gems, giving you access to unique designs you’d otherwise never find.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Intent-Based Browsing&lt;/strong&gt;: Sometimes you don’t know which library you want; you just know you need a “Step Wizard.” Searching by component type across all sources is simply more logical for a fast-moving project.&lt;/li&gt;
&lt;/ul&gt;

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

&lt;p&gt;The “Block Economy” has reached a point where high-quality code is everywhere, but visibility is uneven. The real value of &lt;a href="https://shoogle.dev" rel="noopener noreferrer"&gt;Shoogle.dev&lt;/a&gt; isn’t just that it solves the search problem for developers; it’s that it levels the playing field for the ecosystem. It provides a stage for high-quality shadcn libraries that despite their excellence, often suffer from minimum visibility in a crowded market.&lt;/p&gt;

</description>
      <category>shadcn</category>
      <category>tailwindcss</category>
      <category>react</category>
    </item>
    <item>
      <title>The Cost Structure of Using Nextjs Image</title>
      <dc:creator>Ali Hussein</dc:creator>
      <pubDate>Mon, 16 Sep 2024 16:36:47 +0000</pubDate>
      <link>https://dev.to/alihusseindev/the-cost-structure-of-using-nextjs-image-8dm</link>
      <guid>https://dev.to/alihusseindev/the-cost-structure-of-using-nextjs-image-8dm</guid>
      <description>&lt;p&gt;Using Vercel's image optimization can lead to faster load times, improved user experience, and support for modern image formats like WebP. These benefits can be crucial for maintaining a high-performance application.&lt;/p&gt;

&lt;p&gt;Using Nextjs image isn't completely free. This post will break down the pricing and help you manage your budget effectively.&lt;/p&gt;

&lt;p&gt;The original post is available at &lt;a href="https://indie-starter.dev/blog/the-cost-of-using-nextjs-image" rel="noopener noreferrer"&gt;indie-starter.dev&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Image Optimization Cost&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Vercel's image optimization automatically serves optimized images tailored to your visitors' needs. This can significantly enhance your site's performance by reducing load times and supporting modern image formats.&lt;/p&gt;

&lt;p&gt;Here's a breakdown of how Vercel charges for image optimization based on different plans:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Hobby Plan&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Cost: Free&lt;/p&gt;

&lt;p&gt;Limit: 1,000 image optimizations per month&lt;/p&gt;

&lt;p&gt;Overage: Exceeding this limit results in runtime errors for new images, but no additional charges.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Pro Plan&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Cost: $20/month (base plan cost)&lt;/p&gt;

&lt;p&gt;Limit: 5,000 image optimizations per month&lt;/p&gt;

&lt;p&gt;Overage: $5 per additional 1,000 optimizations&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Fast Data Transfer Cost&lt;/strong&gt;&lt;br&gt;
Requesting images from your website that are hosted on Vercel to add additional usage to your bandwidth or Fast Data Transfer (FDT). &lt;/p&gt;

&lt;p&gt;When a user visits your site, the data transfer between Vercel's Edge Network and them gets measured as Fast Data Transfer (FDT). The data transferred gets measured based on data volume transferred, and can include assets such as your homepage, images, and other static files.&lt;/p&gt;

&lt;p&gt;The first 1 TB of data transfer is free. Beyond that, it costs $0.15 per GB.&lt;/p&gt;

&lt;p&gt;Caching Benefits: Optimized images are cached on Vercel's Edge Network, reducing costs for frequently accessed images.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Edge Requests Cost&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;When visiting your site, requests are made to an Edge Network region. Traffic is routed to the nearest region to the visitor. Static assets and functions all incur Edge Requests. Requests to Edge Network regions are not only for Functions using the edge runtime. Edge Requests are for all requests made to your site, including static assets like images and functions. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Example Scenario&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Let's say you're on the Pro plan and your application optimizes 6,000 images in a month. Here's how your costs would break down:&lt;/p&gt;

&lt;p&gt;Free plan &lt;/p&gt;

&lt;p&gt;Image optimization: 5000&lt;/p&gt;

&lt;p&gt;FDT -&amp;gt; up to 1TB&lt;/p&gt;

&lt;p&gt;Edge Requests: up to  1M&lt;/p&gt;

&lt;p&gt;Total Cost: 0$&lt;/p&gt;

&lt;p&gt;Pro plan&lt;/p&gt;

&lt;p&gt;Base cost: 20$&lt;/p&gt;

&lt;p&gt;Image optimization: 5001 -&amp;gt; +5$ &lt;/p&gt;

&lt;p&gt;FDT -&amp;gt; 10TB + 7GB -&amp;gt; +1.5$ &lt;/p&gt;

&lt;p&gt;Edge Requests: 10M requests + 1 request -&amp;gt; +2$&lt;/p&gt;

&lt;p&gt;Total costs: 28.4$&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Final Thoughts&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Understanding the cost structure of Vercel's image optimization helps you make informed decisions and optimize your budget. By leveraging Vercel's caching and efficient data transfer, you can maximize the benefits of image optimization while keeping costs under control.&lt;/p&gt;

&lt;p&gt;Whether you're on the Hobby, Pro, or Enterprise plan, knowing these details will help you plan effectively and ensure your Next.js application runs smoothly and efficiently.&lt;/p&gt;

</description>
      <category>nextjs</category>
      <category>react</category>
    </item>
    <item>
      <title>Boilerplates are everywhere</title>
      <dc:creator>Ali Hussein</dc:creator>
      <pubDate>Wed, 24 Apr 2024 17:17:02 +0000</pubDate>
      <link>https://dev.to/alihusseindev/boilerplates-are-everywhere-kc9</link>
      <guid>https://dev.to/alihusseindev/boilerplates-are-everywhere-kc9</guid>
      <description>&lt;p&gt;Building boilerplate SaaS became trendy the last few months after some boilerplate providers made a huge success, which encouraged many to build their own boilerplates, and I am one of them. However, I don't want to copy someone else's success story because success stories can't be copied. &lt;/p&gt;

&lt;p&gt;I believe every indie hacker should build his own boilerplate or get at least one. Starting from scratch every time we want to build our own project is time-consuming and counterproductive. Doing repetitive tasks is boring and inefficient. &lt;/p&gt;

&lt;h2&gt;
  
  
  What encouraged me to build &lt;a href="https://indie-starter.dev?ref=dev.to"&gt;Indie Starter&lt;/a&gt;?
&lt;/h2&gt;

&lt;p&gt;By having a solid foundation, I can use it for my own projects and MVPs without starting from scratch and doing repetitive tasks. Beginning with what matters to the end users gets me close to the market, which is a competitive advantage.&lt;/p&gt;

&lt;p&gt;Getting to know other fellow indie makers is not just great motivation; it's also an invaluable opportunity for collaboration and mutual growth. Building a network of like-minded individuals who share similar aspirations and challenges can open doors to exciting collaborations and partnerships. &lt;/p&gt;

&lt;h2&gt;
  
  
  Indie Starter is now available
&lt;/h2&gt;

&lt;p&gt;While new boilerplates are popping up every now and then, it has become increasingly challenging for newcomers to stand out. But despite that, I believe there is room for improvement.&lt;/p&gt;

&lt;p&gt;After hours of working on the demos and the landing page, I am excited to share Indie Starter with other indie hackers and developers to try out. Out of the box, you will have a lot of things already done, such as third-party integrations, global configuration, pre-built core components, and pages.&lt;/p&gt;

&lt;p&gt;If you want to share your feedback about your experience using &lt;a href="https://indie-starter.dev?ref=dev.to"&gt;Indie Starter&lt;/a&gt;, feel free to send a &lt;a href="https://twitter.com/AliHussein_20"&gt;DM&lt;/a&gt;, and I'll send you a coupon code for a discount on your next purchase!&lt;/p&gt;

&lt;h2&gt;
  
  
  Make 💰 with me
&lt;/h2&gt;

&lt;p&gt;I set up a program on Lemon Squeezy🍋 where we can earn money together. Take a peek whenever you want &lt;a href="https://indiestarter.lemonsqueezy.com/affiliates"&gt;Affiliate program&lt;/a&gt;!&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Your Guide for choosing the best-fit NPM package</title>
      <dc:creator>Ali Hussein</dc:creator>
      <pubDate>Sun, 17 Jan 2021 20:29:33 +0000</pubDate>
      <link>https://dev.to/alihusseindev/your-guide-for-choosing-the-best-fit-npm-package-56cn</link>
      <guid>https://dev.to/alihusseindev/your-guide-for-choosing-the-best-fit-npm-package-56cn</guid>
      <description>&lt;p&gt;It is easy to choose when a thing is good and the other is bad, but what to do when both are good! Pros and cons are the answer. Choosing an external 3rd party library takes time, obviously, it is a crucial process. There are many dependencies that do the same thing however nuances make them totally different with a big or little impact on the project. This article will walk you through how to spot the best-fit library for your project, the way I personally do.&lt;/p&gt;

&lt;h1&gt;
  
  
  First Look
&lt;/h1&gt;

&lt;p&gt;there are several sites where we can check some stats about a given library and discover alternatives either. Which is awesome. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Key points I check&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Bundle size&lt;/strong&gt;:  &lt;a href="https://bundlephobia.com"&gt;bundlephobia&lt;/a&gt;  is great, I normally compare the package I am checking with a list of suggested packages which give me an idea of how big/small the bundle size is. &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--NSbWG9qT--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1610659046833/hJL9RXxfP.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--NSbWG9qT--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1610659046833/hJL9RXxfP.png" alt="pure-react-carousel-1-27-6-BundlePhobia.png"&gt;&lt;/a&gt;&lt;br&gt;
I make sure also that it is an ESM library, which allows me to import only the code that I use. which reduces the bundle size.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Library Dependencies&lt;/strong&gt;: zero dependencies is optimal.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Actively maintained:&lt;/strong&gt; this is a sign of healthy dependency. ****&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Security and vulnerability&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Language&lt;/strong&gt;: I prefer Typescript because it has features such as type-safety, autocompletes, and declaration files.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;License&lt;/strong&gt;: A lot of libraries are under MIT, which allows for commercial or private use and /or modify it or distribute it, they don’t provide a warranty of any kind nor liability.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;who&lt;/strong&gt; use or sponsor it. it means users and sponsors believe in its value.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;number of contributors&lt;/strong&gt; more is better&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Issues on GitHub&lt;/strong&gt; obviously less is better. However, many issues are not relevant to my case, so I just ignore them.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Resources where you can see library stats&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://bundlephobia.com/"&gt;bundlephobia.com&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://openbase.io/"&gt;openbase.io&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://snyk.io/advisor/search?q=xstate"&gt;snyk.io/advisor&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.npmtrends.com/"&gt;npmtrends.com&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://npmcompare.com/compare/"&gt;npmcompare.com&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://moiva.io/"&gt;moiva.io&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h1&gt;
  
  
  Customizability
&lt;/h1&gt;

&lt;p&gt;Stats are not enough to detect the best-fit. A demo or more with the chosen library can reveal things that are not stated in the stats. For example, customizability is probably a deal-breaker if it is a UI library. We likely want to customize it to fit into an existing design. In some cases, the customizability offered by UI libraries is not enough or the workaround is not straightforward. However, customizability becomes trivial for projects such as prototyping or MVP.&lt;/p&gt;

&lt;h1&gt;
  
  
  Motivation &amp;amp; Doc
&lt;/h1&gt;

&lt;p&gt;I like to check the documentation, to see if I can walk through the APIs easily or not. I check if there are possible compatibility issues with other packages, I am not aware of.&lt;br&gt;
I like to see what motivates the authors to spend time and effort coding their library. What kind of problems they want to solve, other existing libraries do not. Why it is better than the existing solutions. have a look at these examples&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;...avoid including implementation details so refactors of your components (changes to implementation but not functionality) don't break your tests and slow you and your team down.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;a href="https://testing-library.com/docs/"&gt;testing-library.com&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Glider.js was born out of a frustration for carousels, especially on mobile devices. Inspired by the well-known Slick.js, Glider.js aims to be a fast, lightweight, responsive, unopinionated, dependency-free carousel alternative...&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;a href="https://nickpiscitelli.github.io/Glider.js/"&gt;Glider.js&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Business Value
&lt;/h2&gt;

&lt;p&gt;I like to consider resources such as time, developer experience, money...etc. I usually check if dependencies have an impact on business resources, this is helpful when we have two "good" candidates. e.x Enzyme versus Testing-library, from only business perspectives, Testing-library saves us a lot of time and reduces staff cost for companies because it tests the final results, and it does not test implementation details.&lt;/p&gt;




&lt;p&gt;Thanks for reading. Let me know I missed something.&lt;/p&gt;

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