Write components using CSS only
MistCSS is a new, better and faster way to write visual components. CSS-in-JS? Nope! JS-from-CSS 👍
@scope (button.custom-button) {
:scope {
background: black;
color: white;
&[data-variant="primary"] {
background: blue;
}
&[data-variant="secondary"] {
background: gray;
}
}
}
import { CustomButton } from './Button.mist'
export const App = () => (
<CustomButton variant="primary">Save</CustomButton>
)
You can create React, Astro and Hono components. You can also use Tailwind CSS.