<?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: Sai Madhan</title>
    <description>The latest articles on DEV Community by Sai Madhan (@madhanz0).</description>
    <link>https://dev.to/madhanz0</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.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F709043%2Fbe43773a-2e5f-4ed5-9146-4fc699fc0695.png</url>
      <title>DEV Community: Sai Madhan</title>
      <link>https://dev.to/madhanz0</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/madhanz0"/>
    <language>en</language>
    <item>
      <title>What Happened to Certainty at Work?</title>
      <dc:creator>Sai Madhan</dc:creator>
      <pubDate>Sat, 08 Aug 2026 13:03:53 +0000</pubDate>
      <link>https://dev.to/madhanz0/what-happened-to-certainty-at-work-4d0o</link>
      <guid>https://dev.to/madhanz0/what-happened-to-certainty-at-work-4d0o</guid>
      <description>&lt;p&gt;I have had a few friends come to me recently, complaining about their work.&lt;/p&gt;

&lt;p&gt;It is not always about the work itself. It is more about not knowing what is happening. There are rumours about layoffs, processes ending, teams changing, and projects moving around. Nobody seems to have a clear answer, and I can see what that uncertainty is doing to them.&lt;/p&gt;

&lt;p&gt;This whole thought started with one of my friends.&lt;/p&gt;

&lt;p&gt;She works for a large organization in a non-technical role. It is a repetitive process, and she has been doing it for about five years now. Things have been going well. The job pays her well, she is comfortable with the work, and she has been able to build her life around the stability it gives her.&lt;/p&gt;

&lt;p&gt;She did not feel the need to move somewhere else or completely change her career.&lt;/p&gt;

&lt;p&gt;And there is nothing wrong with that.&lt;/p&gt;

&lt;p&gt;Some people value career progression. They want to learn more, take on bigger roles, and constantly move towards the next thing.&lt;/p&gt;

&lt;p&gt;Others value reliability. They value knowing what their work is, knowing what it pays, and knowing that they can make commitments based on it.&lt;/p&gt;

&lt;p&gt;A job can simply be a job that gives someone a comfortable life.&lt;/p&gt;

&lt;p&gt;It does not have to become their identity or a never-ending challenge. They do not have to constantly turn themselves into a different person just to prove that they are growing.&lt;/p&gt;

&lt;p&gt;For years, the job gave her exactly what it promised. Nothing more, nothing less. Because of that, she could make promises outside the organization. She could plan her expenses, take on responsibilities, and build a life around the income and stability she had.&lt;/p&gt;

&lt;p&gt;Now there are rumours that the process may be going away, and that one change has created a whole chain of uncertainty.&lt;/p&gt;

&lt;p&gt;Nobody knows what will happen to the people working there. Nobody knows whether they will be moved, retrained, or asked to leave.&lt;/p&gt;

&lt;p&gt;Everything is unclear.&lt;/p&gt;

&lt;p&gt;I am not saying that an organization should never expect its employees to change, adapt, or learn new things.&lt;/p&gt;

&lt;p&gt;That is a reasonable expectation.&lt;/p&gt;

&lt;p&gt;Roles change. Clients move on. Projects end. Processes become outdated. Organizations restructure. Change is inevitable.&lt;/p&gt;

&lt;p&gt;But the way an organization handles that change makes a huge difference.&lt;/p&gt;

&lt;p&gt;When a role changes, the organization has to understand what the role is becoming. The manager has to know what is needed for the process to continue and what the employee must learn to continue contributing within it.&lt;/p&gt;

&lt;p&gt;You cannot simply tell everyone to upskill and leave the rest to them.&lt;/p&gt;

&lt;p&gt;Upskill into what?&lt;/p&gt;

&lt;p&gt;What is the process becoming? What skills will actually be useful? What will the employee be expected to do six months from now? Is there a path for them to move from where they are into the new role?&lt;/p&gt;

&lt;p&gt;Asking someone to adapt is reasonable. Keeping them uncertain about what they are supposed to adapt to is not.&lt;/p&gt;

&lt;p&gt;What is one of the most valuable things an employee can offer an organization?&lt;/p&gt;

&lt;p&gt;The first thing that comes to my mind is dependability.&lt;/p&gt;

&lt;p&gt;I believe one of the most meaningful things you can do for your career, no matter what your role is, is make a promise and deliver it.&lt;/p&gt;

&lt;p&gt;You tell your manager that you will complete something by a particular date, and then you complete it.&lt;/p&gt;

&lt;p&gt;When you do that repeatedly, people begin to trust you. Managers can plan around your work. Timelines can be communicated to customers and clients. Other teams know when they can begin their part.&lt;/p&gt;

&lt;p&gt;That predictability makes a meaningful difference to both the employee and the organization.&lt;/p&gt;

&lt;p&gt;But if an organization expects certainty from an employee, should the employee not be able to expect some certainty from the organization too?&lt;/p&gt;

&lt;p&gt;No company can promise that a role will exist forever or that nothing will ever change. Change is part of how organizations survive.&lt;/p&gt;

&lt;p&gt;What employees should still be able to expect is some clarity about what is happening.&lt;/p&gt;

&lt;p&gt;What is changing? Why is it changing? What does the organization expect from the employee? What can the employee do to adapt? Is the process ending? Is another role available? When can people expect an actual answer?&lt;/p&gt;

&lt;p&gt;Even saying, “We do not know yet, but we will have a decision by this date,” is better than leaving everyone in silence.&lt;/p&gt;

&lt;p&gt;Uncertainty does not lead to productivity.&lt;/p&gt;

&lt;p&gt;Once someone begins wondering whether they will have a job next month, every conversation with their manager starts to carry a second meaning.&lt;/p&gt;

&lt;p&gt;They begin wondering whether they should apply elsewhere, cancel a plan, or reconsider a financial commitment they have already made.&lt;/p&gt;

&lt;p&gt;Their attention is no longer entirely on the work.&lt;/p&gt;

&lt;p&gt;That is not because they suddenly became a bad employee. It is because uncertainty has entered every other part of their life.&lt;/p&gt;

&lt;p&gt;Some people adapt quickly when things change. They enjoy learning new things, moving between roles, and figuring things out as they go.&lt;/p&gt;

&lt;p&gt;Others need more time, clearer direction, or a stronger sense of stability before they can adapt.&lt;/p&gt;

&lt;p&gt;A manager cannot assume that every employee will respond to change in the same way.&lt;/p&gt;

&lt;p&gt;They have to understand the people on their team. They need to know their strengths, how they work, what kind of support they need, and where they may be able to contribute when the process changes.&lt;/p&gt;

&lt;p&gt;An organization has the same responsibility.&lt;/p&gt;

&lt;p&gt;People, process, and profit are tied together. They are not separate things that can be changed independently without affecting one another.&lt;/p&gt;

&lt;p&gt;People keep the process working. The process allows people to deliver value. That value eventually becomes profit.&lt;/p&gt;

&lt;p&gt;When a company ignores one of these and focuses only on the others, the whole system starts to weaken.&lt;/p&gt;

&lt;p&gt;Most processes began as an answer to a real problem.&lt;/p&gt;

&lt;p&gt;Someone before the current manager made a decision based on the problems they faced at that time. A person may have stayed in the same role for five years because they understand the work and remain valuable there.&lt;/p&gt;

&lt;p&gt;This is where I think the answer to most complicated problems begins with one simple question.&lt;/p&gt;

&lt;p&gt;Why?&lt;/p&gt;

&lt;p&gt;Why does this process exist?&lt;/p&gt;

&lt;p&gt;Why does this person work in this role?&lt;/p&gt;

&lt;p&gt;Why have they remained there for so long?&lt;/p&gt;

&lt;p&gt;Why was the system designed this way?&lt;/p&gt;

&lt;p&gt;Why is something no longer working?&lt;/p&gt;

&lt;p&gt;Ask those questions before taking a sledgehammer to the whole thing.&lt;/p&gt;

&lt;p&gt;Companies sometimes dismantle teams and processes, only to realise later that the work still needs to be done. Then they recreate similar roles, rebuild the same systems, or hire different people to solve problems that the previous employees were already handling.&lt;/p&gt;

&lt;p&gt;Moving fast and breaking things may work in some situations.&lt;/p&gt;

&lt;p&gt;It should not become an excuse to stop thinking.&lt;/p&gt;

&lt;p&gt;Layoffs are part of this conversation too.&lt;/p&gt;

&lt;p&gt;I understand that layoffs are not always avoidable. Projects end. Clients leave. Revenue changes. An organization may no longer need a certain process or may not be able to afford the number of people it currently employs.&lt;/p&gt;

&lt;p&gt;A difficult decision may have to be made.&lt;/p&gt;

&lt;p&gt;But how the company handles that decision still matters.&lt;/p&gt;

&lt;p&gt;Cloudflare’s recent layoffs are one example of a company at least trying to reduce the damage. In &lt;a href="https://blog.cloudflare.com/building-for-the-future/" rel="noopener noreferrer"&gt;the company’s announcement&lt;/a&gt;, affected employees in the United States were offered base pay and continued healthcare through the end of 2026, giving them more time and space to decide what came next.&lt;/p&gt;

&lt;p&gt;That does not make losing a job easy. It does not remove the pain or uncertainty that comes with it.&lt;/p&gt;

&lt;p&gt;But it recognises that people cannot rebuild lives they planned around their income in a few weeks.&lt;/p&gt;

&lt;p&gt;People may have dedicated years of their time and energy to a company because the company made them feel comfortable and secure. That comfort allowed them to make promises outside the organization.&lt;/p&gt;

&lt;p&gt;They may have taken a loan. They may be supporting their family. They may have planned an education, a marriage, a move, or something else that depends on the income they were told they could rely on.&lt;/p&gt;

&lt;p&gt;Giving someone a short notice period and telling them to use it to find another job is not much of a transition plan.&lt;/p&gt;

&lt;p&gt;AI has now become part of this conversation too.&lt;/p&gt;

&lt;p&gt;I understand the value it can bring to an organization. It can improve productivity, automate parts of a process, and change how certain work is done.&lt;/p&gt;

&lt;p&gt;But the existence of AI does not mean everything has to be replaced with AI.&lt;/p&gt;

&lt;p&gt;Before replacing a person, a role, or an entire process, the organization has to understand why it exists. What problem does this person solve? What knowledge will disappear when they leave? What looks simple only because someone has spent years making it work smoothly?&lt;/p&gt;

&lt;p&gt;Can the employee use the new tools instead of being replaced by them?&lt;/p&gt;

&lt;p&gt;Can the process evolve without throwing away everyone who currently understands it?&lt;/p&gt;

&lt;p&gt;I still believe dependability matters. Employees should make promises they can keep and deliver what they say they will.&lt;/p&gt;

&lt;p&gt;But that relationship has to work both ways.&lt;/p&gt;

&lt;p&gt;No organization can guarantee permanent employment. It can still be honest about what is happening, clear about what is expected, and considerate of the fact that employees make decisions about their lives based on the stability their jobs provide.&lt;/p&gt;

&lt;p&gt;People can handle change. They can learn, move, adapt, and begin again.&lt;/p&gt;

&lt;p&gt;Keeping them uncertain does not prepare them for change.&lt;/p&gt;

&lt;p&gt;It only leaves them standing in the same place, wondering when the ground beneath them is going to move.&lt;/p&gt;

</description>
      <category>career</category>
      <category>ai</category>
      <category>discuss</category>
      <category>management</category>
    </item>
    <item>
      <title>Why I Waited to Publish</title>
      <dc:creator>Sai Madhan</dc:creator>
      <pubDate>Sat, 08 Aug 2026 13:00:56 +0000</pubDate>
      <link>https://dev.to/madhanz0/why-i-waited-to-publish-2i93</link>
      <guid>https://dev.to/madhanz0/why-i-waited-to-publish-2i93</guid>
      <description>&lt;p&gt;It has been a long time since I published anything here.&lt;/p&gt;

&lt;p&gt;I have wanted to write for a while now. There have been plenty of ideas, half-finished drafts, and moments when I thought, “I should probably publish this.” But somehow, they always remained drafts.&lt;/p&gt;

&lt;p&gt;Over time, I realized it was not because I could not write. It was because I cared about what I was writing.&lt;/p&gt;

&lt;p&gt;The internet has no shortage of words. Every topic has already been written about in a thousand different ways, and I do not want to add another page to that pile simply because I feel I should keep publishing.&lt;/p&gt;

&lt;p&gt;I want to write about things that stay with me. Ideas I have wrestled with for days, sometimes months. Things I have learned while building software, problems that changed the way I think, questions that do not have simple answers, or observations that refuse to leave my mind.&lt;/p&gt;

&lt;p&gt;I could probably publish much more if I lowered that bar. I could turn every passing thought into a post, polish it until it looked finished, and move on to the next one.&lt;/p&gt;

&lt;p&gt;But I know myself.&lt;/p&gt;

&lt;p&gt;A week later, I would read it again and wonder why I published it in the first place. Eventually, I would probably delete it.&lt;/p&gt;

&lt;p&gt;I would rather have a small collection of things that genuinely mattered to me than hundreds of posts that exist only because I felt I should keep publishing.&lt;/p&gt;

&lt;p&gt;So, that is what this space is.&lt;/p&gt;

&lt;p&gt;A place for ideas that I believe are worth remembering.&lt;/p&gt;

&lt;p&gt;I do not know how often those ideas will arrive. But when something stays with me long enough, I think this is where it will end up.&lt;/p&gt;

</description>
      <category>learning</category>
      <category>software</category>
      <category>writing</category>
    </item>
    <item>
      <title>Building a Tech Startup: Why Your Tech Stack Should Follow Your Business Model, Not the Other Way Around</title>
      <dc:creator>Sai Madhan</dc:creator>
      <pubDate>Sun, 09 Nov 2025 16:00:01 +0000</pubDate>
      <link>https://dev.to/madhanz0/building-a-tech-startup-why-your-tech-stack-should-follow-your-business-model-not-the-other-way-o52</link>
      <guid>https://dev.to/madhanz0/building-a-tech-startup-why-your-tech-stack-should-follow-your-business-model-not-the-other-way-o52</guid>
      <description>&lt;p&gt;As a software engineer, I've had the privilege of working alongside some of the smartest people I know in both technology and business. Through these experiences and my own study, I've developed the ability to evaluate product development through dual lenses: technical feasibility and business viability. Recently, a conversation with an aspiring founder illustrated something I've been thinking about: &lt;strong&gt;how easy it is to let AI-generated technical advice override critical thinking and domain expertise&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  When Tools Replace Critical Thinking
&lt;/h2&gt;

&lt;p&gt;Someone recently approached me with what they described as a revolutionary idea—a fashion and lifestyle e-commerce platform combining AI, VR, and AR capabilities. They presented an extraordinarily complex tech stack document featuring custom infrastructure, self-hosted ML operations, multiple database engines, and microservices architecture.&lt;/p&gt;

&lt;p&gt;For someone with no technical background, this list was suspiciously comprehensive. It became clear they had assembled this entire technical strategy using AI tools. The architecture looked impressive on paper but revealed several critical misjudgments:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;No business validation&lt;/strong&gt; - When I asked about market research, vendor relationships, or supply chain, the answer was minimal: two local shop conversations.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Technology before business model&lt;/strong&gt; - They wanted to build custom ML infrastructure and complex microservices before proving anyone wanted the core product.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Misunderstanding of costs&lt;/strong&gt; - They claimed their AI-generated stack would be "less expensive" than my recommendations, despite requiring custom development of everything from scratch.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Dismissing domain expertise&lt;/strong&gt; - When I suggested starting with e-commerce validation first, then layering features, they became defensive. The AI had provided a complete vision, and expertise that contradicted it wasn't welcome.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  The Real Problem
&lt;/h2&gt;

&lt;p&gt;Here's the issue: &lt;strong&gt;AI tools generate technically plausible architectures, but they lack context about your business stage, constraints, and actual needs&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;An AI will recommend enterprise-grade solutions because it's trained on successful companies' architectures. But those companies didn't start there—they evolved to those systems after proving their business model and generating revenue.&lt;/p&gt;

&lt;h2&gt;
  
  
  Business First, Technology Second
&lt;/h2&gt;

&lt;p&gt;When I asked about market validation—existing retail relationships, customer research, vendor partnerships—the answer was thin. No established supply chain, no customer base, no vendor network.&lt;/p&gt;

&lt;p&gt;This is critical because in e-commerce, &lt;strong&gt;your app is not your business&lt;/strong&gt;. Your business is:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Your supply chain&lt;/li&gt;
&lt;li&gt;Your vendor relationships&lt;/li&gt;
&lt;li&gt;Your customer acquisition strategy&lt;/li&gt;
&lt;li&gt;Your fulfillment capabilities&lt;/li&gt;
&lt;li&gt;Your margins and unit economics&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The technology is simply the tool that enables these core competencies. Companies that succeed in this space don't win because of their tech stack—they win because they understand operations, logistics, and customer needs.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Right Way to Build: Start With Your Core Value
&lt;/h2&gt;

&lt;p&gt;My recommendation was straightforward: &lt;strong&gt;build the e-commerce foundation first&lt;/strong&gt;. Here's why:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Validate your business model&lt;/strong&gt; - Can you actually move products? Do customers want what you're selling?&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Build your user base&lt;/strong&gt; - Real users engaging with real products&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Generate revenue&lt;/strong&gt; - Prove the business fundamentals work&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Then layer on features&lt;/strong&gt; - Once you have traction, add AI recommendations, AR try-ons, social features&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;This isn't about lacking ambition. It's about &lt;strong&gt;structured iteration&lt;/strong&gt;. Every successful super app started as a focused product. They expanded once they had proven their core and built a user base.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Cost Conversation
&lt;/h2&gt;

&lt;p&gt;Despite having no technical background, this person claimed their proposed stack would be "less expensive" than my recommendations. Let me share some hard-earned wisdom about tech stack decisions:&lt;/p&gt;

&lt;h3&gt;
  
  
  Start With Leverage, Not Control
&lt;/h3&gt;

&lt;p&gt;For a pre-revenue startup, services like &lt;strong&gt;WorkOS&lt;/strong&gt; for authentication make perfect sense. They offer up to 1M users free. That's not vendor lock-in—that's &lt;strong&gt;business leverage&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Here's the math: If your business is good enough to get 100,000 paying users, you'll have revenue. At that point, migrating to a custom system becomes a &lt;strong&gt;planned business expense&lt;/strong&gt;—a calculated investment funded by actual income.&lt;/p&gt;

&lt;h3&gt;
  
  
  Migration is Part of Growth Strategy
&lt;/h3&gt;

&lt;p&gt;This is something non-technical founders often misunderstand: &lt;strong&gt;migration, refactoring, and technical evolution are normal parts of successful businesses&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;When you're established with revenue:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You have resources to hire specialized engineers&lt;/li&gt;
&lt;li&gt;You have actual usage data to inform optimization decisions&lt;/li&gt;
&lt;li&gt;You have business metrics to justify infrastructure investments&lt;/li&gt;
&lt;li&gt;You have operational margin to fund technical improvements&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The cost of migrating 100K users from WorkOS to a custom auth system might be $50-100K in engineering time. Sounds expensive? Not when you're generating revenue. That's a manageable business expense.&lt;/p&gt;

&lt;p&gt;Building that custom auth system from day one? That's $100K+ spent before you know if anyone wants your product. That's not being cost-conscious—that's burning money.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Reality of "Vendor Lock-in"
&lt;/h3&gt;

&lt;p&gt;When I suggested Cloudflare for CDN and edge services, the response was concern about vendor lock-in. This perfectly illustrated the disconnect between AI-generated fears and business reality.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Real vendor lock-in&lt;/strong&gt; is when switching providers is technically impossible or prohibitively expensive relative to your business scale. Using Cloudflare's CDN isn't lock-in—your content is portable, and migrating to AWS CloudFront or similar services is straightforward when you have the scale to justify it.&lt;/p&gt;

&lt;h3&gt;
  
  
  Building Custom vs. Leveraging Services
&lt;/h3&gt;

&lt;p&gt;The proposed stack implied building machine learning infrastructure from the ground up. This deserves scrutiny.&lt;/p&gt;

&lt;p&gt;Production-grade ML systems require training data you don't have at launch, specialized engineering talent, expensive compute infrastructure, and ongoing operational overhead.&lt;/p&gt;

&lt;p&gt;Modern AI APIs—offering vision, language, and recommendation capabilities—exist precisely to remove this burden. You get to offer sophisticated features without the infrastructure complexity.&lt;/p&gt;

&lt;p&gt;The question isn't "can we build this?" It's "should we build this &lt;strong&gt;now&lt;/strong&gt;, or focus resources on validating our business model?"&lt;/p&gt;

&lt;h2&gt;
  
  
  What Actually Reduces Costs
&lt;/h2&gt;

&lt;p&gt;Here's what genuinely keeps startup costs down:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Use generous free tiers&lt;/strong&gt; - Supabase, Vercel, WorkOS, Cloudflare offer incredible free tiers&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Managed services over self-hosted&lt;/strong&gt; - Your engineering time is your most expensive resource&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Monolith before microservices&lt;/strong&gt; - A well-structured monolith scales to millions of users&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Proven tech over bleeding edge&lt;/strong&gt; - Pick boring technology; it's boring because it works&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Buy don't build&lt;/strong&gt; - Unless it's your core differentiator, use existing solutions&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;And crucially: &lt;strong&gt;Plan for migration as part of business growth&lt;/strong&gt;. It's not a failure to start with managed services and migrate later—it's smart capital allocation.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Real Expense
&lt;/h2&gt;

&lt;p&gt;The real expense isn't Cloudflare or managed services. The real expense is building the wrong thing—spending months building a complex system with self-hosted infrastructure before validating if anyone wants the core product.&lt;/p&gt;

&lt;p&gt;Every dollar and hour spent on custom infrastructure is a dollar and hour not spent on:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Understanding your customers&lt;/li&gt;
&lt;li&gt;Building vendor relationships&lt;/li&gt;
&lt;li&gt;Refining your product-market fit&lt;/li&gt;
&lt;li&gt;Acquiring users&lt;/li&gt;
&lt;li&gt;Generating revenue&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Where Guidance Falls Short
&lt;/h2&gt;

&lt;p&gt;This experience highlighted something I've been observing: &lt;strong&gt;the risk of making decisions in domains where you lack expertise, without consulting those who have it&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Modern tools provide unprecedented access to information. You can research technical architectures, best practices, and industry standards with ease. But information without context can be misleading.&lt;/p&gt;

&lt;p&gt;The challenge isn't access to knowledge—it's &lt;strong&gt;knowing what applies to your specific situation&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  My Advice to Founders
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;If you're technical:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Resist the urge to over-engineer&lt;/li&gt;
&lt;li&gt;Your goal is to validate assumptions as quickly as possible&lt;/li&gt;
&lt;li&gt;Pick tools that let you ship fast, not tools that look impressive on a diagram&lt;/li&gt;
&lt;li&gt;Build from experience, not from AI prompts&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;If you're non-technical:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Find a technical advisor you trust, then &lt;strong&gt;actually listen to them&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Understand that comprehensive technical plans need business context&lt;/li&gt;
&lt;li&gt;"Complete" tech stacks don't guarantee successful products—solving real problems does&lt;/li&gt;
&lt;li&gt;Question technical decisions you don't understand, but respect domain expertise&lt;/li&gt;
&lt;li&gt;The best architecture is the one that gets you to validation fastest&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;When evaluating technical approaches:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Treat AI-generated advice as input, not direction&lt;/li&gt;
&lt;li&gt;Validate recommendations with people who have relevant experience&lt;/li&gt;
&lt;li&gt;Understand that optimal and practical are different things&lt;/li&gt;
&lt;li&gt;Remember that successful companies evolved their infrastructure—they didn't start with it&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The Bottom Line
&lt;/h2&gt;

&lt;p&gt;Your tech stack should be the &lt;strong&gt;last thing&lt;/strong&gt; you optimize, not the first. Start with:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Validate the business model&lt;/li&gt;
&lt;li&gt;Build the minimum product that proves value&lt;/li&gt;
&lt;li&gt;Get real users&lt;/li&gt;
&lt;li&gt;Generate revenue&lt;/li&gt;
&lt;li&gt;Scale and refactor what works&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Migration, refactoring, and technical evolution aren't problems—they're signs of success. They're the "problems" you &lt;strong&gt;want&lt;/strong&gt; to have, because they mean your business is growing.&lt;/p&gt;

&lt;p&gt;The mistake is spending months building comprehensive systems for unproven concepts, guided by impressive-sounding advice that lacks business context.&lt;/p&gt;

</description>
      <category>startup</category>
      <category>product</category>
      <category>ai</category>
      <category>business</category>
    </item>
    <item>
      <title>Building Full-Stack Apps with Bun, React, and Hono: A Modern Approach</title>
      <dc:creator>Sai Madhan</dc:creator>
      <pubDate>Fri, 11 Jul 2025 16:08:12 +0000</pubDate>
      <link>https://dev.to/madhanz0/serving-a-react-app-and-hono-api-together-with-bun-1gfg</link>
      <guid>https://dev.to/madhanz0/serving-a-react-app-and-hono-api-together-with-bun-1gfg</guid>
      <description>&lt;p&gt;I've been exploring Bun lately and I'm impressed by its capabilities. When I decided to try building a full-stack application using Bun with React and Hono, I discovered a surprisingly elegant pattern that I wanted to share.&lt;/p&gt;

&lt;p&gt;If you're looking for a modern, performant way to build full-stack applications, this combination might be exactly what you need.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why This Stack?
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Bun&lt;/strong&gt;: Blazing fast JavaScript runtime with built-in bundling and excellent React support&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;React&lt;/strong&gt;: The frontend framework we all know and love&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Hono&lt;/strong&gt;: Lightweight, fast web framework with excellent TypeScript support and middleware ecosystem&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Setting Up Your Full-Stack App
&lt;/h2&gt;

&lt;p&gt;Let's start by creating a new Bun application with React support:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;bun init &lt;span class="nt"&gt;--react&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;shadcn
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This gives us a React application with shadcn/ui support out of the box. But here's where it gets interesting—Bun's routing system allows us to seamlessly integrate a Hono API server.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Setup: Combining the Best of Both Worlds
&lt;/h2&gt;

&lt;p&gt;Here's how we can set up our server to handle both API routes and React serving:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;serve&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;bun&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;Hono&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;hono&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;index&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;./index.html&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;API&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;./api&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;app&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;Hono&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;span class="nx"&gt;app&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;route&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/api/&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;API&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;server&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;serve&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
  &lt;span class="na"&gt;routes&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/api/*&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;app&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;fetch&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;  &lt;span class="c1"&gt;// API routes handled first&lt;/span&gt;
    &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/*&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;index&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;          &lt;span class="c1"&gt;// React app serves everything else&lt;/span&gt;
  &lt;span class="p"&gt;},&lt;/span&gt;
  &lt;span class="na"&gt;development&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;process&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;NODE_ENV&lt;/span&gt; &lt;span class="o"&gt;!==&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;production&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="na"&gt;hmr&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;console&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="p"&gt;},&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;

&lt;span class="nx"&gt;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="s2"&gt;`🚀 Server running at &lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;server&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;url&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That's it! By mapping &lt;code&gt;/api/*&lt;/code&gt; to &lt;code&gt;app.fetch&lt;/code&gt;, we get a clean separation between our API and frontend, with both served from the same process.&lt;/p&gt;

&lt;h2&gt;
  
  
  Alternative Approaches
&lt;/h2&gt;

&lt;p&gt;You could certainly build your API using Bun's built-in methods directly in the routes configuration:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;server&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;serve&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
  &lt;span class="na"&gt;routes&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/api/users&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="nc"&gt;GET&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;req&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;Response&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt; &lt;span class="na"&gt;users&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[...]&lt;/span&gt; &lt;span class="p"&gt;});&lt;/span&gt;
      &lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/*&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;index&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="p"&gt;},&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Or use Hono's JSX capabilities to build React-style components:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;Hono&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;hono&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;jsx&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;hono/jsx&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;app&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;Hono&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;span class="nx"&gt;app&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;/&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;c&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;c&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;html&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;h1&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="nx"&gt;Hello&lt;/span&gt; &lt;span class="nx"&gt;Hono&lt;/span&gt;&lt;span class="o"&gt;!&amp;lt;&lt;/span&gt;&lt;span class="sr"&gt;/h1&amp;gt;&lt;/span&gt;&lt;span class="err"&gt;)
&lt;/span&gt;&lt;span class="p"&gt;})&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;However, I prefer the approach outlined above because it gives us access to the full React ecosystem—Tailwind CSS, shadcn/ui, and countless React libraries—while still providing a powerful backend with Hono's extensive middleware collection.&lt;/p&gt;

&lt;h2&gt;
  
  
  Project Structure
&lt;/h2&gt;

&lt;p&gt;Here's how I like to organize these projects:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;├── index.ts          # Main server file
├── main.tsx          # React entry point
├── index.html        # HTML template
├── app/
│   └── App.tsx       # React components
├── api/
│   ├── index.ts      # API router
│   └── v1/
│       └── index.ts  # Versioned API routes
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  API Setup with Hono
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;api/index.ts&lt;/strong&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;Hono&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;hono&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;V1Routes&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;./v1&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;API&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;Hono&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;span class="nx"&gt;API&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;route&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/v1/&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;V1Routes&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="nx"&gt;API&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;api/v1/index.ts&lt;/strong&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;Hono&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;hono&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;V1Routes&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;Hono&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

&lt;span class="nx"&gt;V1Routes&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;c&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;c&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt; &lt;span class="na"&gt;message&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Welcome to V1&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;}));&lt;/span&gt;

&lt;span class="nx"&gt;V1Routes&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/books&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;c&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; 
  &lt;span class="nx"&gt;c&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt; 
    &lt;span class="na"&gt;books&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
      &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;title&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;The Great Gatsby&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;author&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;F. Scott Fitzgerald&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
      &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;title&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;To Kill a Mockingbird&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;author&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Harper Lee&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
      &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;title&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;1984&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;author&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;George Orwell&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;]&lt;/span&gt;
  &lt;span class="p"&gt;})&lt;/span&gt;
&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="nx"&gt;V1Routes&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/users&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;c&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; 
  &lt;span class="nx"&gt;c&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt; 
    &lt;span class="na"&gt;users&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
      &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;John Doe&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;email&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;john@example.com&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
      &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Jane Smith&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;email&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;jane@example.com&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;]&lt;/span&gt;
  &lt;span class="p"&gt;})&lt;/span&gt;
&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="nx"&gt;V1Routes&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Adding Client-Side Routing
&lt;/h2&gt;

&lt;p&gt;For a proper SPA experience, you'll want to add React Router:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;bun add react-router-dom
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;App.tsx&lt;/strong&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;BrowserRouter&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;Routes&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;Route&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;react-router-dom&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;App&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;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;BrowserRouter&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Routes&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Route&lt;/span&gt; &lt;span class="na"&gt;path&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"/"&lt;/span&gt; &lt;span class="na"&gt;element&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Home&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Route&lt;/span&gt; &lt;span class="na"&gt;path&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"/about"&lt;/span&gt; &lt;span class="na"&gt;element&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;About&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Route&lt;/span&gt; &lt;span class="na"&gt;path&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"/books"&lt;/span&gt; &lt;span class="na"&gt;element&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Books&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Route&lt;/span&gt; &lt;span class="na"&gt;path&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"*"&lt;/span&gt; &lt;span class="na"&gt;element&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;NotFound&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;Routes&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;BrowserRouter&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The beauty of this setup is that Bun's &lt;code&gt;"/*": index&lt;/code&gt; route serves your React app for all non-API requests, giving you client-side routing that works perfectly with React Router.&lt;/p&gt;

&lt;h2&gt;
  
  
  One Important Detail
&lt;/h2&gt;

&lt;p&gt;When using &lt;code&gt;app.route()&lt;/code&gt; with this setup, make sure to include the trailing slash:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="nx"&gt;app&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;route&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/api/&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;API&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="c1"&gt;// ✅ Works&lt;/span&gt;
&lt;span class="c1"&gt;// app.route("/api", API); // ❌ Won't work&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;However, individual route handlers work as expected without any special configuration:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="nx"&gt;V1Routes&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/books&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;handler&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="c1"&gt;// Works at /api/v1/books&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  What You Get
&lt;/h2&gt;

&lt;p&gt;With this setup, you get:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;API endpoints&lt;/strong&gt; at &lt;code&gt;/api/v1/books&lt;/code&gt;, &lt;code&gt;/api/v1/users&lt;/code&gt;, etc.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;React app&lt;/strong&gt; served from &lt;code&gt;/&lt;/code&gt; with full client-side routing&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Hot module replacement&lt;/strong&gt; for React components&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Single process&lt;/strong&gt; serving both frontend and backend&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Type safety&lt;/strong&gt; across your entire stack&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Full React ecosystem&lt;/strong&gt;: Tailwind CSS, shadcn/ui, and thousands of React libraries&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Hono's middleware ecosystem&lt;/strong&gt; for authentication, CORS, logging, validation, and more&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Best of both worlds&lt;/strong&gt;: Modern frontend tooling with a powerful, flexible backend&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Performance Benefits
&lt;/h2&gt;

&lt;p&gt;This approach gives you several performance advantages:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Bun's speed&lt;/strong&gt;: Both your API and frontend benefit from Bun's performance&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No proxy overhead&lt;/strong&gt;: Everything runs in the same process&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Efficient bundling&lt;/strong&gt;: Bun handles all the heavy lifting for your React app&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Fast startup&lt;/strong&gt;: Your entire stack boots up quickly&lt;/li&gt;
&lt;/ul&gt;

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

&lt;p&gt;Building full-stack applications with Bun, React, and Hono is remarkably straightforward once you understand how all three interact with each other. The combination gives you modern tooling, excellent performance, and a clean development experience.&lt;/p&gt;

&lt;p&gt;Whether you're building a personal project or a production application, this stack provides a solid foundation with room to grow. The integration feels natural, and you get the best of all three technologies without any awkward compromises.&lt;/p&gt;

&lt;p&gt;Give it a try—I think you'll be pleasantly surprised by how well these tools work together!&lt;/p&gt;

</description>
      <category>fullstack</category>
      <category>bunjs</category>
      <category>react</category>
      <category>hono</category>
    </item>
  </channel>
</rss>
