The Nx Plugin for Rsbuild contains executors and generators that support building applications using Rsbuild. In an Rsbuild monorepo, it wires each project into Nx so you can build, serve, and cache them from a single workspace.
Requirements
Section titled “Requirements”The @nx/rsbuild plugin supports the following package versions.
| Package | Supported Versions | Default Installed |
|---|---|---|
@rsbuild/core | ^1.0.0 | 1.1.10 |
Nx generators install the latest supported version automatically when scaffolding new projects. When @rsbuild/core is already installed in your workspace, generators detect the installed version and keep it in place rather than overwriting it.
Setting up @nx/rsbuild
Section titled “Setting up @nx/rsbuild”Installation
Section titled “Installation”In any Nx workspace, you can install @nx/rsbuild by running the following command:
nx add @nx/rsbuildThis will install the correct version of @nx/rsbuild.
Using @nx/rsbuild
Section titled “Using @nx/rsbuild”Generate a new project using Rsbuild
Section titled “Generate a new project using Rsbuild”You can generate a new application that uses Rsbuild with the following command:
nx g @nx/react:app myapp --bundler=rsbuildThis will create a new application configured to use Rsbuild for building.
Set up CI for your Rsbuild monorepo
Section titled “Set up CI for your Rsbuild monorepo”In CI, Nx runs nx affected to rebuild and retest only the projects a change touches, and caches results to skip repeated work.
For a complete pipeline, see Set up CI.