Rspack built-in CSS
pluginRspackBuiltinCss is an experimental plugin that replaces css-loader, style-loader, and CssExtractRspackPlugin with Rspack's built-in css/* module types.
The plugin preserves loaders added by PostCSS, Lightning CSS, Sass, Less, and other plugins.
CSS Modules
Configure CSS Modules through output.cssModules. The plugin supports:
auto: boolean valuesexportLocalsConventionlocalIdentNamemode:local,global, andpurenamedExport
The following values are not supported and emit warnings:
- RegExp and function values for
auto exportGlobalsicssand function values formode
Use the plugin options to configure Rspack parser and generator fields that are not covered by output.cssModules:
The parser option supports exportType, url, import, resolveImport, animation, container, customIdents, dashedIdents, function, and grid.
The generator option supports esModule, localIdentHashDigest, localIdentHashDigestLength, localIdentHashFunction, and localIdentHashSalt.
CSS ?url imports are not supported.

