Skip to main content

css_in_js_object_sheets

Function css_in_js_object_sheets 

Source
pub fn css_in_js_object_sheets(source: &str, path: &Path) -> CssInJsObjectSheets
Expand description

Lift the object-notation CSS-in-JS in a JS/TS source into the structural / structural-partial / atomic virtual stylesheets. Parses with oxc (source type inferred from path), maps import bindings to recognized libraries, walks for style calls, serializes each bucket, and pads each to its source line. All sheets are None when the source has no recognized object CSS-in-JS import.