The Anatomy of Scalability: Finding My Ideal React Structure
May 1, 2026
8 min
In a world where AI and new technologies are fundamentally changing how we build, one thing remains constant: the need for a clear foundation. Tools evolve, but the anatomy of a scalable application tends to follow the same principles of logic and isolation. Over the past three years, I’ve deliberately studied how others structure their projects—how they name folders and maintain clarity in their codebases. All that input led me somewhere: a way of structuring projects that I genuinely stand behind. This article is a kind of public notebook of that process. It’s not the one “correct” approach, but it’s mine—and I’m happy to explain why.
1
The challenge
Preventing ‘folder chaos‘ and tightly coupled logic as projects grow in size and complexity.
2
Solution
A modular ‘core‘ architecture that isolates business logic, networking, and UI components.
3
Approach
Using domain-specific modules, central networking interceptors, and a ‘dumb‘ design system.
4
Outcome
A predictable, scalable skeleton that reduces cognitive load and speeds up development.
The Blueprint: A Bird’s-Eye View
Whether I’m working on a Next.js web project or a mobile app with Expo (React Native), the foundation I set up is almost identical. A project should be predictable. If I return to it after a month, I don’t want to waste time figuring out where everything lives.
My current structure looks like this:
src/
├── app/ # The "Traffic Controller": Routing & Layouts
├── assets/ # Everything from brand assets to icons and images
├── components/ # Visual building blocks
│ ├── design/ # Pure UI / Design System (Buttons, Typography)
│ └── functional/ # Smart components (Forms, Auth)
├── core/ # The "Brain" of the application
│ ├── hooks/ # General, technical hooks
│ ├── modules/ # Domain-specific logic (API, Types, Utils)
│ ├── networking/ # Base configuration for API communication
│ ├── locale/ # Internationalization (i18n)
│ └── utils/ # Global helpers
└── data/ # Mock data or static configurations
Side note:
src/assetsvs.public/While
src/assetsoffers technical benefits (like bundler optimizations), I sometimes intentionally use thepublic/folder instead. When working with hundreds of images tied to API data, manually importing them becomes impractical. Inpublic/, you can simply construct paths like:src={/assets/items/${id}.png}. This keeps your code clean when dealing with large media sets.
1. The Gateway: Central Networking (core/networking)
Before diving into features, there’s one place that handles all communication: core/networking/api.ts. This is the foundation.
Here lives my central Axios setup: baseURL, timeout, and interceptors for auth tokens. From that point on, I never have to think about HTTP configuration anywhere else in the codebase. Every module simply imports the preconfigured instance. If the API URL changes or a new header is needed, it’s a single change in one place.
2. Core Modules: Isolated Business Logic
The most important part of this structure is src/core/modules. In many projects I’ve seen, API calls live in a large /api folder and types in a massive /types folder. That works for small apps—but as soon as things grow, it turns into chaos.
Everything related to a specific feature belongs together. A module like “vouchers” looks like this:
core/modules/vouchers/
├── api.ts # Uses the axios instance from core/networking
├── types.ts # TypeScript interfaces for this domain
└── utils.ts # Calculations or data transformations for vouchers
The api.ts inside a module is intentionally lean—it only contains endpoint definitions and data mapping. The heavy configuration remains safely inside the networking layer. And since utils.ts lives alongside it, it’s immediately clear that this logic is domain-specific.
3. Design vs. Functional: Separation of Concerns
I maintain a strict separation between how something looks and what it does.
Design Components: Pure UI
This is my UI kit: buttons, inputs, cards. The rule is simple—design is “dumb.” These components know nothing about databases or complex state. They can receive an onClick, but what happens on click doesn’t belong here.
Functional Components: The Bridge
In the functional layer, I build components that connect everything. A ContactForm.tsx pulls data from hooks in core/modules, manages form state, and uses design components to render the UI.
4. A Favorite Detail: Typography via Dot Notation
One thing I’ve experimented with a lot is how to implement text styles. Instead of a collection of separate components, I use a structured Text object:
<Text.Heading1>This is a title</Text.Heading1>
<Text.Paragraph bold italic>This is important text.</Text.Paragraph>
I export this as a single object via an index.ts in my typography folder. As soon as I type <Text., code completion shows all available styles—from Heading1 to Footnote. It saves time and makes available options immediately visible.
5. The "Thin Route" Strategy
Whether I’m using Next.js or Expo Router, I keep route files as thin as possible. A route acts as a traffic controller: it connects data from core with components from functional on a single page—and nothing more.
When I open a page file, I want to understand its structure at a glance, without scrolling through hundreds of lines of business logic.
6. In Practice: Green Guide Gent
I apply this structure extensively in the development of the Green Guide Gent (opens in a new tab) app. As more features are added, the foundation remains stable. Everything lives in modules, networking is centralized.
That creates confidence: even six months from now, the codebase remains maintainable. And if I — or another developer — decide to revisit or refactor parts of it, it’s immediately clear where to start.
Conclusion: Calm Code, Clear Mind
Most project frustration doesn’t come from technical complexity — it comes from a structure you no longer understand. What I’ve described here is my answer to that problem. It forces me to think before I start typing.
This isn’t a final destination. The perfect folder structure probably doesn’t exist, because every project and team has different needs. But by consciously choosing isolation and predictability, you build a foundation your future self — and your teammates — will be grateful for.