Frontend Tooling 2026: Vite, Rsbuild & Bun Cheat Sheet
Bottom Line
If you are replacing Webpack in 2026, Vite is the safest default, Rsbuild is the smoothest path for large Webpack-shaped apps, and Bun is the sharpest option when you want one binary to own runtime, package management, and bundling.
Key Takeaways
- ›As of April 28, 2026, stable release lines are Vite 8, Rsbuild 1.6, and Bun 1.3.
- ›Vite 8 now builds with Rolldown, with the team citing up to 10-30x faster builds.
- ›Rsbuild keeps the most Webpack-like migration path while exposing simpler defaults over Rspack.
- ›Bun is strongest when you want a single tool for install, run, test, and bundle, not when you need maximum legacy-browser flexibility.
As of April 28, 2026, replacing Webpack 5 no longer means choosing between raw speed and a workable developer experience. Vite 8, Rsbuild 1.6, and Bun 1.3 each cover a different migration shape: mainstream app tooling, Webpack-adjacent enterprise builds, and single-binary full-stack workflows. This cheat sheet focuses on commands, config, defaults, and the practical cut lines that matter when you are standardizing a frontend stack.
| Dimension | Webpack | Vite | Rsbuild | Bun | Edge |
|---|---|---|---|---|---|
| Primary role | Config-heavy bundler | Dev server + production build tool | App framework over Rspack | Runtime + package manager + bundler | Bun |
| Best fit | Existing mature setups | Default modern frontend apps | Large apps moving off Webpack | Bun-native apps and small full-stack stacks | Depends |
| Default dev port | 8080 with webpack serve | 5173 | 3000 | No single app-scaffold default | Rsbuild |
| Migration familiarity | Native | Moderate rewrite | Highest | Lowest | Rsbuild |
| Plugin ecosystem | Deep but older | Strong and mainstream | Growing, app-focused | Narrower | Vite |
| Single-tool coverage | No | No | No | Yes | Bun |
| Production build engine | Webpack | Rolldown in Vite 8 | Rspack | Native Bun bundler | Depends |
| Config inspectability | Manual | Good, plugin-driven | Built-in inspect command | Lower-level API/CLI | Rsbuild |
Replacement Matrix
Bottom Line
Vite is the default recommendation. Pick Rsbuild when your migration risk is mostly config and ecosystem churn, and pick Bun when consolidating runtime, package manager, and bundler is the actual goal.
- Vite 8 is the biggest strategic shift here because production builds now run on Rolldown, not the older Rollup-based path Vite used for years.
- Rsbuild remains the most comfortable option for teams that still think in terms like asset prefixes, generated config, and bundler internals.
- Bun is not just a bundler swap. It changes how you install packages, run scripts, bundle code, and sometimes how you structure frontend entrypoints.
- Webpack is still viable, but it is no longer the default answer for greenfield browser apps.
When To Choose Each Tool
Choose Vite when:
- You want the safest default for React, Vue, Svelte, Solid, or vanilla frontend work.
- You want a mature plugin ecosystem and mainstream docs coverage.
- You want fast local iteration without preserving a Webpack-shaped mental model.
- You are standardizing across multiple frontend repos and want the lowest training cost.
Choose Rsbuild when:
- You are migrating a large Webpack codebase and want fewer conceptual jumps.
- You want Rspack performance with a higher-level app config surface.
- You need a built-in way to inspect generated config through rsbuild inspect.
- You want migration headroom without dropping into raw bundler configuration on day one.
Choose Bun when:
- You want one binary for install, run, test, and build.
- You are comfortable with Bun-native workflows and lighter plugin expectations.
- You are building full-stack or static HTML-driven apps where Bun’s HTML imports fit naturally.
- You care more about operational simplicity than preserving existing Webpack conventions.
Commands By Purpose
Use the live filter to narrow commands by tool, purpose, or flag. Press / to focus the filter and Esc to clear it.
Scaffold
Vite
npm create vite@latest
npm create vite@latest my-app -- --template react-tsRsbuild
npm create rsbuild@latestBun
bun create vite my-app
bun create ./MyComponent.tsxRun Dev Servers
Vite
npx vite
npx vite --port 3000 --open
npx vite --strictPortRsbuild
npx rsbuild
npx rsbuild dev --open
npx rsbuild dev --port 8080 --host 0.0.0.0Bun
bunx --bun vite
bun run dev
bun ./index.htmlBuild Production Output
Vite
npx vite build
npx vite build --outDir dist-app --sourcemap hidden
npx vite build --target modulesRsbuild
npx rsbuild build
npx rsbuild build --watch
npx rsbuild build --mode productionBun
bun build ./src/index.tsx --outdir ./dist
bun build ./src/index.tsx --outdir ./dist --target browser --splitting
bun build ./index.html --outdir=dist --env=PUBLIC_* --sourcemap --minifyPreview And Inspect
Vite
npx vite preview
npx vite preview --port 4173 --openRsbuild
npx rsbuild preview
npx rsbuild inspect --mode production
npx rsbuild inspect --verboseBun
bun build ./src/index.tsx --outdir ./dist --watch
bun build ./src/index.ts --outfile app --compileConfiguration Patterns
Vite: base path, alias, ports, preview
import { defineConfig } from 'vite'
import { fileURLToPath, URL } from 'node:url'
export default defineConfig({
base: '/docs/',
resolve: {
alias: {
'@': fileURLToPath(new URL('./src', import.meta.url)),
},
},
server: {
port: 5173,
strictPort: true,
open: true,
},
preview: {
port: 4173,
},
build: {
outDir: 'dist',
sourcemap: true,
},
})- Use server.port when you want a fixed dev port and preview.port when local production previews need a separate port.
- Use base when deploying under a subpath like
/docs/. - Use define only for constant replacement, not general runtime env access.
Rsbuild: React plugin, aliases, base path, asset prefix
import { defineConfig } from '@rsbuild/core';
import { pluginReact } from '@rsbuild/plugin-react';
export default defineConfig({
plugins: [pluginReact()],
resolve: {
alias: {
'@': './src',
},
},
server: {
base: '/app',
port: 3000,
},
output: {
assetPrefix: 'https://cdn.example.com/assets/',
distPath: {
root: 'dist',
},
},
html: {
title: 'Rsbuild App',
},
});- Rsbuild looks for config files like
rsbuild.config.mjs,rsbuild.config.ts, andrsbuild.config.jsat the project root. - Use server.base for route prefixing and output.assetPrefix for production asset URLs such as CDN paths.
- Public env vars use the PUBLIC_ prefix and are available through
import.meta.envandprocess.env.
Bun: bundle browser code directly
await Bun.build({
entrypoints: ['./src/index.tsx'],
outdir: './dist',
target: 'browser',
splitting: true,
sourcemap: 'external',
minify: true,
env: 'PUBLIC_*',
define: {
__APP_VERSION__: JSON.stringify('1.0.0'),
},
});- Use target values browser, bun, or node depending on where the bundle will run.
- Use env: 'PUBLIC_*' to inline only safe public variables instead of every env var.
- Bun’s env replacement works on literal
process.env.FOOreferences, notimport.meta.env.
Advanced Workflows
Debug what the tool is actually doing
- Vite: use --debug and --profile when plugin or startup behavior is opaque.
- Rsbuild: use rsbuild inspect to dump resolved Rsbuild and Rspack config.
- Bun: prefer the JavaScript Bun.build() API when CLI flags stop scaling.
# Vite
npx vite --debug
# Rsbuild
npx rsbuild inspect --mode production --verbose
# Bun
bun build ./src/index.tsx --outdir ./dist --watchMap common Webpack habits to 2026 replacements
- Replace long dev-server setup with Vite or Rsbuild defaults first, then re-add only the behavior you still need.
- Move CDN path logic into Vite base or Rsbuild output.assetPrefix instead of carrying forward custom public path glue.
- Keep Bun for cases where HTML entrypoints or single-binary operations reduce more complexity than they add.
- Treat migration as workflow replacement, not just config translation.
Reference links used for this cheat sheet
- Vite getting started, Vite CLI, Vite server options, Vite 8 announcement, Vite releases
- Rsbuild quick start, Rsbuild CLI, Configure Rsbuild, Rsbuild server.port, Rsbuild releases
- Bun bundler, bun create, Vite with Bun, Bun HTML and static sites, Bun releases
- Webpack getting started, Webpack CLI commands
Keyboard Shortcuts
| Shortcut | Action | Why it matters |
|---|---|---|
/ | Focus the live command filter | Fastest way to narrow the cheat sheet |
Esc | Clear the filter | Reset back to the full command list |
g c | Jump to Commands | Useful during migration sessions |
g k | Jump to Configuration | Go straight to config examples |
g a | Jump to Advanced | Open the debugging and migration notes |
? | Jump to Shortcuts | Self-discover the article controls |
Frequently Asked Questions
Is Bun a full replacement for Vite in 2026? +
bunx --bun vite, but its best fit is a Bun-native workflow where runtime, install, and build are intentionally unified. If your team depends on the broadest frontend plugin ecosystem, Vite is still the safer default.Should I migrate from Webpack to Vite or Rsbuild first? +
Does Vite 8 still use Rollup for production builds? +
What is Rsbuild’s biggest advantage over raw Rspack or Webpack? +
@rsbuild/plugin-react, and a built-in rsbuild inspect command, while still sitting on top of Rspack for performance.What should I verify before replacing Webpack with Bun? +
Get Engineering Deep-Dives in Your Inbox
Weekly breakdowns of architecture, security, and developer tooling — no fluff.
Related Deep-Dives
Vite 8 Migration Checklist
A practical checklist for moving existing frontend apps onto the Vite 8 stack.
System ArchitectureRspack vs Webpack for Enterprise Teams
A team-level comparison of migration risk, config complexity, and build performance.
Developer ToolsBun as Runtime, Package Manager, and Bundler
Where Bun’s all-in-one model simplifies JavaScript delivery and where it still adds tradeoffs.