Stylus is an Expressive, dynamic and robust CSS preprocessor. With Stylus plugins, you can use Stylus as the CSS preprocessor.
You can install the plugin using the following command:
You can register the plugin in the rsbuild.config.ts file:
After installing the plugin, you can directly import *.styl or *.module.styl files into the code without adding other configs.
normalize.styl:title.module.styl:index.js:If you need to customize the compilation behavior of Stylus, you can use the following configs.
-Type:
undefinedOptions passed to Stylus, please refer to the Stylus documentation for specific usage.
booleanisDevWhether to generate Source Map, enabled by default in the development environment.