Stylist tailwind contains a bunch of tailwind classes that you can use in Stylist.
Add the following to your Cargo.toml
:
stylist-tailwind = "0.2.0"
For detailed usage, please see documentation.
use yew::prelude::*;
use stylist::Style;
#[styled_component]
fn MyStyledComponent() -> Html {
html! {<div class={Style::new(tw!("w-full px-4 my-8")).unwrap()}>{"Hello World!"}</div>}
}