AI-assisted engineering

Rewriting a production app in one week

Leading a Svelte-to-Next.js rewrite to unify the technology stack, from documented user flows to feature-parity testing and a monitored production cutover.

Client and organization names are withheld.

Type
Project account
Role
Technical direction and hands-on delivery
Conceptual illustration, not a screenshot of the client system.

Unify the stack without losing the product

The organization wanted to bring an existing Svelte application onto Next.js so its applications shared a consistent technology stack. This was a production application with a substantial set of features already in use. The rewrite needed to preserve those capabilities while introducing the new implementation and updated branding. I approached it as a production transition, with understanding the existing product and verifying its replacement built into the delivery plan.

Make the existing behavior explicit

I evaluated the application’s features and used AI-assisted exploration to map its user flows. I turned that understanding into a functional specification document (FSD) and established 13 architecture decision records (ADRs) for the rebuild. I defined architecture boundaries and quality gates, alongside authentication and backend-for-frontend (BFF) patterns and a Vercel AI SDK streaming foundation. This gave the implementation a defined scope and a set of decisions to work from, with a basis for checking whether the new application retained the behavior people relied on.

A first pass in one day

Using a model focused on front-end implementation, I produced the initial Next.js rewrite within one day, working from the specification and architecture decisions. That first pass gave us an application we could evaluate against the production version. It was the beginning of validation: generating the implementation quickly made more of the week available for finding discrepancies and resolving them.

Spend the time on parity and quality

Most of the remaining week went into manually testing the documented use cases and comparing the two applications. This exposed UI details that needed adjustment and functionality that was missing or behaved differently. We logged tickets for the discrepancies and worked through the fixes. Feature-parity checks and quality assurance accounted for most of the effort, because a convincing first impression was not enough to establish that the rewrite was ready for production.

Validate the transition in production

When the replacement was ready, we ran both services in parallel and routed traffic with active monitoring to check that the Next.js application behaved as expected. We completed the cutover after we were satisfied with its functionality. Keeping both implementations available during the transition let us assess the replacement in operation before completing the move.

The outcome and the engineering judgment

The rewrite and migration were completed within a week, with the first implementation produced in a day and most of the time devoted to verification. The result moved the application onto the organization’s chosen Next.js stack. My contribution connected the platform direction with the practical work of specification, architecture, implementation, testing and cutover. AI accelerated implementation; the delivery depended on making the requirements explicit and checking the generated application against them.

A GOOD PLACE TO START

What are you
working on?

A product to build. A team to lead.
A question about where AI fits.

Let’s talk