Compare
Slab vs React Aria, Radix and Base UI
All of them leave the design to you. React Aria, Radix and Base UI are built for React. Slab works anywhere HTML does.
01 The short version
React Aria, Radix and Base UI are great headless libraries, and they're built for React. Slab is a set of custom elements, so the same package works in React, Vue, Svelte, Ember, a server-rendered template or a plain HTML file. If your company has more than one framework, one Slab covers all of them. And when you change frameworks, your components come with you.
02 Slab in React
React 19 supports custom elements, so a Slab element takes properties and events like any other. There's no wrapper package. Slab ships types for React's JSX, so your editor knows every tag, attribute and event.
import 'slab-elements/checkbox.js';
import type {} from 'slab-elements/react.js';
export function Terms() {
return <slab-checkbox label="I agree" name="terms" required />;
}
Frameworks in Get started shows events and the other frameworks.
03 Forms without glue
Slab's controls are form-associated. A plain <form> submits, validates and resets them, with no state to keep and no form library to wire up. They follow the native API too: value, checkValidity(), setCustomValidity(), "input" and "change". That works the same in a React app as on a page with no framework at all.
04 What you give up
It's not all free. A React library renders its markup on the server. A Slab element is empty until its script runs. You style Slab's insides through ::part() and :state(), so utility classes reach an element's host and what you slot into it, but not its parts. And React Aria has years of use at Adobe behind it, with internationalized dates across many calendar systems.
Slab is tested in Chromium, Firefox and WebKit, with Axe, ARIA snapshots and keyboard tests on every component. Accessibility says what has been checked by hand and what hasn't.
05 Which to pick
It comes down to how many frameworks you need to support, now and later.
-
React Aria, Radix or Base UI
You're all in on React, and you want server rendering and React's own patterns.
-
Slab
You use more than one framework, or none, or want components that outlive the one you use today.
Get started has the rest: installing, servers, testing and what each element weighs.