Integrations
Set up Master CSS in Rspack
Guide to setting up Master CSS in your Rspack project.
Create a project
If you don't have a Rspack project, create one first.
npm create rspack@latest my-appcd my-appAdd Master CSS
Run the installer in static mode from the Rspack project root. Static mode scans complete class strings and emits generated CSS at build time.
npm create @master/css@rc -- --framework rspack --mode static --yesStart dev server
Run the command to start the Rspack dev server.
npm run devStart using Master CSS
Now style your first Rspack page using Master CSS syntax.
localhost:8080
Hello World
The installer registers the Webpack-compatible plugin in rspack.config.* and creates src/index.css as the Master CSS entry.
import MasterCSSPlugin from '@master/css.webpack'export default { module: { rules: [ { test: /\.css$/i, type: 'css/auto' } ] }, plugins: [ new MasterCSSPlugin({ mode: 'static' }) ]}@import '@master/css';<h1 class="m:2xl italic font:5xl font:heavy text:neutral"> Hello World</h1>