compile and watch commands unless otherwise noted.
Output flags
Output file path for the compiled StyleSheet.Format inference:
.luauextension → Luau format.rbxmxextension → RBXMX format- No extension → Luau format
compile, watchExplicitly set the output format, overriding automatic inference.Valid values:
luau- Generate Luau module (recommended)rbxmx- Generate RBXMX model file (experimental)
--output file extensionAvailable in: compile, watchName assigned to the root StyleSheet instance.Available in:
compile, watchWarning flags
Control the level of warnings emitted during compilation.Valid values:
all- Show all warnings (unsupported properties, selectors, units, etc.)unsupported- Show only warnings about unsupported CSS featuresnone- Suppress all warnings
compile, watchTreat warnings as errors. Compilation will fail (exit code 1) if any warnings are emitted.Useful for CI/CD pipelines where you want to enforce zero warnings.Available in:
compile onlyNot available in
watch mode to avoid disrupting development workflow.Output optimization
Minify the generated Luau output by removing whitespace and comments.Only applies to: Luau format (has no effect on RBXMX output)Available in:
compile onlyToken flags
Emit CSS custom properties (design tokens from
:root) as a separate StyleSheet instance instead of embedding them in the main StyleSheet.Available in: compile onlyThis is useful when you want to share design tokens across multiple StyleSheets or manage them independently.
Metadata flags
Generate a Produces:
.manifest.json file alongside the output containing metadata about the compiled stylesheet.Manifest contents:- Classes that use
overflow: scroll(helps tools like rbx-tsx upgradeFrametoScrollingFrame) - Other compilation metadata
--output must be specified (doesn’t work with stdout)Available in: compile onlyExample:StyleSheet.luauStyleSheet.manifest.json
Global flags
Display the rbx-css version number and exit.
Display help information for a command.
Flag compatibility matrix
| Flag | compile | watch |
|---|---|---|
-o, --output | ✓ | ✓ |
--name | ✓ | ✓ |
--format | ✓ | ✓ |
--warn | ✓ | ✓ |
--strict | ✓ | ✗ |
--minify | ✓ | ✗ |
--tokens-sheet | ✓ | ✗ |
--manifest | ✓ | ✗ |
Examples
Minimal compile
Production build
Development with watch
Multiple input files with custom name
Related
- rbx-css compile - Compile command documentation
- rbx-css watch - Watch command documentation