Next.js 16+ and Turbopack — incremental bundling, FS caching, dev speed, and when to use Turbopack vs webpack.
Comprehensive Next.js and Turbopack skill for OpenCode — covers incremental bundling, file-system caching, dev server optimization, bundle analysis, and migration between Turbopack and webpack. Triggered when the user mentions Next.js, Turbopack, webpack, bundling, or dev server performance.
Activate this skill when user input contains:
When reviewing or configuring Next.js/Turbopack setups:
next dev runs with Turbopack unless disabled..next; no extra config needed for basic use.next dev
next build
next start
Turbopack (default dev): Use for day-to-day development. Faster cold start and HMR, especially in large apps.
Webpack (legacy dev): Use only if you hit a Turbopack bug or rely on a webpack-only plugin in dev. Disable with --webpack (or --no-turbopack depending on your Next.js version; check the docs for your release).
Production: Production build behavior (next build) may use Turbopack or webpack depending on Next.js version; check the official Next.js docs for your version.
Run next dev for local development with Turbopack. Use the Bundle Analyzer (see Next.js docs) to optimize code-splitting and trim large dependencies. Prefer App Router and server components where possible.
.next cache directory not being unnecessarily clearednext build completes successfullyUser: "My Next.js dev server is slow"
Assistant: Activates nextjs-turbopack skill. Checks if Turbopack is enabled (default in 16+), verifies cache isn't being cleared, and suggests Bundle Analyzer for heavy deps.
User: "How do I analyze my Next.js bundle size?"
Assistant: Uses nextjs-turbopack skill to guide enabling the experimental Bundle Analyzer and interpreting results.
User: "Should I use Turbopack or webpack for my Next.js project?"
Assistant: Applies nextjs-turbopack skill. Recommends Turbopack (default in 16+) for dev unless hitting specific bugs or webpack-only plugin requirements.
User: "Configure Next.js for optimal dev experience"
Assistant: Leverages nextjs-turbopack skill to set up Turbopack defaults, caching, and bundle analysis tooling.
Following Agent Skills specification for progressive disclosure and best practices.