Compiler types
CompileOptions
Configuration options for thecompile() function.
Name for the generated StyleSheet instance
Warning verbosity level:
"all", "unsupported", or "none"When
true, warnings are treated as errorsWhen
false, skip auto-generated base element rules. Defaults to trueCompileResult
Return type of thecompile() function.
The compiled intermediate representation
Warning collector with diagnostics
Map of class names to whether they use
overflow: scrollLuauOptions
Configuration options for thegenerateLuau() function.
When
true, removes comments and indentationOptional source filename to include in generated comments
Intermediate representation types
StyleSheetIR
The root intermediate representation of a compiled stylesheet.StyleSheet instance name
Design tokens extracted from
:root CSS custom propertiesArray of compiled style rules
Optional theme variations (from
[data-theme] or @media (prefers-color-scheme))StyleRuleIR
A single compiled style rule.The Roblox selector (e.g.,
".card", "Frame", "TextButton.primary")Map of Roblox property names to values
Array of pseudo-instance declarations (currently unused; pseudo-instances are emitted as separate rules with
::Component selectors)PseudoInstanceIR
A pseudo-instance declaration (e.g.,UICorner, UIStroke).
The type of Roblox instance (e.g.,
"UICorner", "UIStroke")Map of property names to values for this instance
PseudoInstanceType
Supported pseudo-instance types.Value types
RobloxValue
A Roblox property value in the IR. Can be any of the following types:TokenValue
A design token value from:root CSS custom properties.
Warning types
WarningLevel
Warning verbosity level."all"— Show all warnings"unsupported"— Only show warnings about unsupported CSS features"none"— Suppress all warnings
WarningCode
Warning category codes.CompilerWarning
A single compiler warning.Warning category code
Human-readable warning message
Source filename (if available)
Line number in source file (if available)
Column number in source file (if available)
WarningCollector
Warning collector class for managing compilation diagnostics.Warning verbosity level (defaults to
"all")When
true, any warnings are treated as errors (defaults to false)warn(warning)— Add a warninggetWarnings()— Get all collected warningshasErrors()— Returnstrueif strict mode is enabled and warnings existformat()— Format warnings as a string (one per line)
Manifest types
CSSManifest
Metadata about the compiled stylesheet.Map of CSS class names to metadata (e.g., whether they use
overflow: scroll)Map of HTML element names to Roblox instance class names (e.g.,
{ "div": "Frame" })Related
- compile() — Compile CSS to IR
- generateLuau() — Generate Luau code
- generateRBXMX() — Generate RBXMX XML