Skip to main content

Farm vs Vite vs Turbopack: Next-Gen Bundlers 2026

·PkgPulse Team

TL;DR

Vite 6 is still the best default bundler for most projects — 16M weekly downloads and ecosystem maturity nothing can match. Turbopack shipped stable in Next.js 15 and is the only choice for new Next.js apps going forward. Farm is the fastest raw bundler (Rust-native with JS plugin compatibility), but its ecosystem and documentation are still catching up. The bundler wars of 2023-2024 largely settled: Vite won the app space, Turbopack won the Next.js space, Rspack won the Webpack migration space.

Key Takeaways

  • Vite 6: 16M downloads/week, Rolldown migration in progress (Rust internals coming), ecosystem gold standard
  • Turbopack: Stable in Next.js 15, 700K downloads/week (via @next/turbopack), 10x faster than Webpack for Next.js
  • Farm: ~50K downloads/week, written fully in Rust, fastest cold start, Vite plugin compatibility
  • Rspack: 1.2M downloads/week, fastest Webpack drop-in replacement (separate article)
  • For React/Vue/Svelte apps: Vite is the answer (not close)
  • For Next.js: Turbopack via next dev --turbopack

Downloads

PackageWeekly DownloadsTrend
vite~16M↑ Growing
@next/turbopack (via next)~6M↑ Growing
@rspack/core~1.2M↑ Fast growing
@farmfe/core~50K↑ Growing

Vite 6: The Standard

# New project:
npm create vite@latest my-app -- --template react-ts

# In existing project:
npm install --save-dev vite @vitejs/plugin-react
// vite.config.ts:
import { defineConfig } from 'vite';
import react from '@vitejs/plugin-react';
import tsconfigPaths from 'vite-tsconfig-paths';

export default defineConfig({
  plugins: [
    react(),
    tsconfigPaths(),
  ],

  build: {
    target: 'es2022',
    rollupOptions: {
      output: {
        // Manual chunks for better caching:
        manualChunks: {
          vendor: ['react', 'react-dom'],
          router: ['react-router-dom'],
          query: ['@tanstack/react-query'],
          ui: ['@radix-ui/react-dialog', '@radix-ui/react-dropdown-menu'],
        },
      },
    },
  },

  server: {
    port: 3000,
    // Fast HMR — no full reload on module graph changes:
    hmr: { overlay: true },
  },

  // Vite 6: new environment API for SSR:
  environments: {
    client: { optimizeDeps: { include: ['react', 'react-dom'] } },
    ssr: { resolve: { conditions: ['module', 'node'] } },
  },
});

Vite 6 Performance

Dev server cold start (React app, 200 deps):
  Vite 5:  1.8s
  Vite 6:  1.2s (improved dep pre-bundling)

HMR (hot module replacement):
  Vite:    ~50ms average (esbuild transform)
  Webpack: ~800ms average

Build (500 component React app):
  Vite:    12.4s (Rollup)
  Vite + Rolldown (preview): 3.1s (Rust Rollup port)
  Webpack: 45s

Turbopack: Native in Next.js 15

# Enable in Next.js 15 (stable):
npm run dev  # Turbopack is now default in Next.js 15!

# next.config.ts:
import type { NextConfig } from 'next';

const nextConfig: NextConfig = {
  // Turbopack is default — configure if needed:
  turbopack: {
    // Custom resolvers:
    resolveExtensions: ['.tsx', '.ts', '.jsx', '.js', '.json'],
    
    // Rules for non-standard files:
    rules: {
      '*.svg': {
        loaders: ['@svgr/webpack'],
        as: '*.js',
      },
    },
  },
};

export default nextConfig;

Turbopack Performance (Next.js 15)

Next.js 15 with Turbopack vs Webpack:

Cold start (large app, 1000 modules):
  Turbopack:  1.4s
  Webpack:    14.2s

HMR (React component edit):
  Turbopack:  ~180ms
  Webpack:    ~2.1s

Full rebuild:
  Turbopack: Incremental only — rebuilds affected graph
  Webpack:   ~30s full

Production build:
  Turbopack (stable v15): Uses Webpack for production builds
  (Pure Turbopack production build: expected late 2026)

Note: Turbopack production builds still use Webpack in Next.js 15.x. Dev-only Turbopack is what you get today. Full production Turbopack is coming.


Farm: Rust-Native Speed

npm install --save-dev @farmfe/core @farmfe/plugin-react
// farm.config.ts:
import { defineConfig } from '@farmfe/core';
import farm_react from '@farmfe/plugin-react';

export default defineConfig({
  plugins: [
    farm_react({ refresh: true }),
  ],

  compilation: {
    input: { index: './index.html' },
    output: { path: './dist' },
    
    // Target browser compatibility:
    script: { target: 'es2022' },
    
    // Partial bundling — Farm's unique approach:
    // Groups modules into partial bundles to balance request count vs bundle size
    partialBundling: {
      enforceResources: [
        {
          name: 'vendor',
          test: ['node_modules/react', 'node_modules/react-dom'],
        },
      ],
    },
  },

  server: {
    port: 9000,
    hmr: true,
  },

  // Vite plugin compatibility (most Vite plugins work!):
  vitePlugins: [
    '@vitejs/plugin-legacy',  // Can use Vite plugins in Farm
  ],
});

Farm Performance

Dev server cold start (React app, 200 deps):
  Farm:   0.4s  ← Rust startup, no esbuild dep pre-bundle
  Vite:   1.2s
  Webpack: 8s

HMR:
  Farm:   ~30ms  (incremental Rust compilation)
  Vite:   ~50ms
  Webpack: ~800ms

Production build:
  Farm:   4.2s
  Vite:   12.4s
  Webpack: 45s

Ecosystem Comparison

Vite 6TurbopackFarm
EcosystemMassive (1000+ plugins)Next.js onlySmall (growing)
Vite plugin compatNativePartial (vitePlugins)
Production build✅ Rollup❌ (still Webpack)
Framework supportReact, Vue, Svelte, etc.Next.js onlyReact, Vue, Svelte
Config complexityLowMinimalLow
Rust internalsPartial (Rolldown coming)
CommunityLargeLarge (via Next.js)Small

Decision Guide

Use Vite if:
  → Any non-Next.js project (React, Vue, Svelte, vanilla)
  → Need rich plugin ecosystem
  → SvelteKit, Nuxt, Remix (Vite is built-in)
  → Stable, well-documented, proven in production

Use Turbopack if:
  → Next.js 15+ project
  → Already using Next.js — it's the default
  → Large Next.js codebase with slow Webpack dev server

Use Farm if:
  → Coldest possible dev starts are critical
  → Small project, can tolerate smaller ecosystem
  → Want Vite plugin compatibility with Rust speed
  → Research/benchmarking new tooling

Use Rspack if:
  → Existing Webpack codebase needing faster rebuilds
  → Need drop-in Webpack replacement
  → Can't afford migration to Vite config

Compare Vite, Farm, Turbopack, and Rspack on PkgPulse.

Comments

Stay Updated

Get the latest package insights, npm trends, and tooling tips delivered to your inbox.