irwin@notes: ~/post/webpack-to-turbopack

Why I Switched from Webpack to Turbopack

2026-01-228 min read
#webpack#turbopack#dx

I spent years optimizing Webpack configs, but for this project the maintenance cost kept climbing. I moved to Turbopack to reduce config overhead and speed up local feedback loops.

What improved immediately

  • Fast startup when opening the project
  • Noticeably shorter rebuild times while editing React components
  • Better defaults with less custom config to maintain

What I had to watch for

Some markdown and MDX plugins expect serializable config values. If a plugin setup relies on function references, it may fail in Turbopack and need string-based plugin config instead.

next.config.ts
const withMDX = createMDX({
  options: {
    remarkPlugins: ["remark-gfm"],
    rehypePlugins: [["rehype-pretty-code", { theme: "github-dark-dimmed" }]],
  },
});

Bottom line

For this codebase, Turbopack gave me a cleaner setup and faster day-to-day iteration. If your build pipeline is very customized, test plugin compatibility early.