Hulu had already been using Next.js for greenfield applications, so it was an obvious option when it came to choosing which framework to move to. This time, however, the team needed to migrate an existing production app—a challenge that comes with new difficulties of its own.

At the beginning of 2018, senior software engineer Zack Tanner and team began leading the migration of the Hulu Account app off of a legacy tech-stack, with the goal of unifying the developer organization and modernizing their code in an effort to prevent bugs and increase velocity.

Process Improvements

Migration Made Easy

One of the most common challenges teams face when executing an incremental migration is handling the transition between the new and old systems. Fortunately, with Next.js there was never an issue with running both versions at once. With out-of-the-box support for prefetching new pages while jumping into the legacy app when needed, Zack and the team were able to easily migrate pages one-by-one. And since the intermediary hybrid-site was intelligently routed by Next.js, there was no need to maintain the overhead of explicitly tracking the migration's progress in the code itself.

In fact, throughout the migration, the ability of Next.js to make the extraction of common issues and patterns as easy as possible was a recurring theme. With each new version of Next.js, Zack and the team found they were constantly deleting internal code in favor of framework integrated tooling. Whenever the team needed to incorporate a new technology, Next.js had either first-class support or an endorsed example for them to follow.