pub trait IntoTailwindClass {
    // Required methods
    fn to_class(&self) -> String;
    fn with_class(&self, class: impl AsRef<str>) -> String;
}
Expand description

A trait to convert a type into a Tailwind class. Implemented automatically for usages of TwClass and TwVariant.

Required Methods§

source

fn to_class(&self) -> String

Convert the type into a Tailwind class.

source

fn with_class(&self, class: impl AsRef<str>) -> String

Append to the class (with override precedence) and return the new class.

Object Safety§

This trait is not object safe.

Implementors§