
Today I want to share the story behind DirectoryStack v2.0 - specifically the journey that led to this complete rewrite. This isn't just another product update announcement. Instead, I want to walk you through my thought process and the technical decisions that ultimately made v2.0 necessary and, more importantly, better for everyone. It was a significant undertaking that I'm actually quite proud of, and I think understanding the "why" behind it will help you appreciate what we've built.
First, let me be clear - v1 wasn't bad. It was actually a solid codebase that many of you have built successful directories with. But as I kept adding features and supporting more customers, some fundamental issues became impossible to ignore.
The biggest issue with v1 was its monolithic structure. All components were in the components folder, all server actions in the server actions folder, and so on. This might sound organized, but it created a maintenance nightmare.
Every time I wanted to add a new feature or fix a bug, I had to touch multiple parts of the codebase. And then I had to create detailed update guides for all past clients explaining exactly what files to change and how. It was time-consuming and error-prone.
As some of you know, I initially launched DirectoryStack with three different templates: Essential, Standard, and Pro. This seemed like a good idea at the time - different options for different needs.
But in reality, 95% of customers bought the Pro version anyway. Meanwhile, I was maintaining three separate codebases, which tripled my workload. It quickly became clear this approach wasn't sustainable for a small team (just me, actually).
After discontinuing the Essential and Standard templates, I still had the problem of how to add new features to the Pro template. Not every client needed every feature, so I put everything behind feature flags.
This created another problem: when I released a new feature, past clients had to update their code in multiple places to add both the feature and its feature flag. The update guides got longer and more complex.
The turning point came when a customer wanted a way to capture leads. Instead of integrating it directly into the monolith, I built it as a standalone module and provided instructions for adding it to their codebase.
This worked surprisingly well! The module was self-contained, easy to add, and didn't require massive changes throughout their codebase. This got me thinking about a completely different approach to DirectoryStack.
Around the same time, React 19 and Next.js 15 were released with significant improvements. I initially tried to upgrade the existing codebase, but after some painful iterations, I realized it would be easier to start from scratch.
This wasn't an easy decision. It meant losing about 1.5 months of development time. But looking at the long-term benefits, I knew it was the right move.
The new v2.0 is built around two key principles:
-
Feature-driven folder structure: Instead of organizing by technical function (components, server actions, etc.), the code is organized by features or as I call them "modules". Everything related to listings is in the "listings" module, everything for managing users is in the "user management" module, and so on.
-
Modular architecture: The codebase is now split into 13 core modules and 8 shared modules. The core and the shared modules are always installed. I call this the "Foundation". I believe every directory can use these modules. Next, I am introducing extension modules. These can be added to your project if you need them. Want to capture leads? Just add the "Lead Capture" extension module. Fancy a blog? Just add it. You get the idea.
This approach has huge benefits:
- When I release a new feature or module, I can simply provide the module folder to clients
- Clients can pick and choose exactly what they need
- Updates are isolated to specific modules, not spread throughout the codebase
- The core is lighter and more maintainable
Beyond the architectural changes, v2.0 includes:
- Upgraded to Next.js 15 & React 19
- Changed from MDX to HTML content
- All configuration is now done in the admin section instead of in a config file
- Added a notification system
- More detailed KPIs with a dedicated dashboard
- LLM Observability with spending tracking
- Internationalization with 4 languages out of the box
- Improved error handling with Sentry.io
- Better SEO capabilities
- Improved user experience with better search, filtering, and sorting
- Better TypeScript support and documentation
- Improved security with CSP and Supabase RLS
- And much more
To be completely transparent, v2.0 doesn't yet have all the features of v1. RBAC, Secondary Listings, Promoted Listings, and Ad Management are still missing. But they're coming soon, and the new architecture means they'll be better than before.
If you're using DirectoryStack or considering it, this rewrite means:
- A more stable and maintainable codebase
- Easier updates and new features
- The ability to customize exactly what you need
- A future-proof foundation built on the latest technologies
I'm not going to pretend this rewrite was easy or that v2.0 is perfect. There's still work to do. But I'm genuinely proud of what I've built, and I believe it's a much stronger foundation for the future of DirectoryStack.
In a market with many directory templates, I want DirectoryStack to stand out not just for its features, but for its architecture, flexibility, and maintainability. I believe v2.0 achieves that.
I'm excited to see what you'll build with it, and I'm looking forward to your feedback as DirectoryStack continues to improve.
Best,
Till