style_with_vars

Macro style_with_vars 

Source
style_with_vars!() { /* proc-macro */ }
Expand description

Style macro with CSS variables support

Usage:

let class = style_with_vars! {
    --primary-color: #007bff;
    --spacing: 16px;
     
    .component {
        color: var(--primary-color);
        padding: var(--spacing);
    }
};

This macro parses CSS variables (–name: value) and regular CSS, ensuring variables are properly scoped and available for use.