Rspack CLI
$ rspack Official Low RiskOfficial CLI (@rspack/cli) for the Rust-written Rspack bundler offering near-drop-in Webpack compatibility at Rust speed. Supports rspack build --json stats output and --no-color for deterministic headless builds.
npm install -g @rspack/cli Local Rust-accelerated bundler run directly inside frontend repositories.
Agent-Readiness Checklist
Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.
FCRS-1.0 6-Dimension Breakdown
Supports rspack build --json and --no-color without interactive prompts, though rspack dev is a blocking server and --json stats are verbose.
- Supports
rspack build --jsonand--no-color - Non-interactive
buildsubcommand
Local compilation scoped to dist/, though rspack.config.* JS plugins run with local Node permissions.
- Zero network or credential exposure
Installed via npm/npx with prebuilt Rust native bindings for macOS, Linux, and Windows.
- Cross-platform npm packages with native binaries
Dramatically faster build times than Webpack while preserving Webpack config and plugin compatibility.
- Rust-powered parallel bundling and SWC transpilation
Maintained by ByteDance Web Infra (web-infra-dev/rspack) under MIT with rapid adoption.
- Active
web-infra-dev/rspackrepository
Clear CLI reference and migration guides at rspack.dev.
- Official CLI documentation at rspack.dev/api/cli
Security, Auth & Guardrails
No authentication required; reads local rspack.config.* and project source files.
MIT open-source CLI; completely free.
# Rspack CLI (rspack) Agent Rules - Use `rspack build --no-color` for synchronous verification; redirect `--json` to a file before filtering with `jq`. - Run `rspack dev` or `rspack preview` only in background daemon tasks.
Agent-Ready Command Recipes
Safe Read-Only Queries
rspack --version && rspack build --help
Reports the installed @rspack/cli version and build options without touching output folders.
Controlled Writes & Previews
rspack build --json --no-color > dist/stats.json
Bundles the project at native Rust speed and writes Webpack-compatible JSON stats to dist/stats.json.
Strengths for Agents
- + Combines Webpack
--jsonstats compatibility with Rust build performance. - + Clean
rspack build --no-colorverification flow.
Caveats & Pitfalls
- !
--jsonoutputs large Webpack-style stats objects that should be redirected or filtered withjq. - !
rspack devblocks synchronously if not started as a background daemon.