Skip to content

Improve css util #368

@owjs3901

Description

@owjs3901

The css uitl can not be used with dynamic variables like this.

css({ w: "100%" }) // OK
css({ w: v }) // Impassible

Because, dynamic variables are applied through the style prop, While the css util works without JSX syntax.

However, you can use the css util with dynamic variables inside jsx..

css({ w: v}) // still not allowed

const a = <Box className={css({w: v})} /> // OK

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions