/ariakit

Toolkit for building accessible web apps with React

Primary LanguageTypeScriptMIT LicenseMIT

Ariakit

Toolkit for building accessible web apps with React.
Explore website »


NPM version GitHub (Pre-)Release Date GitHub Discussions
NPM downloads   GitHub Repo stars   Follow Ariakit on Twitter


This is the Ariakit (v2) branch (What is Ariakit?), which is still in alpha.
If you're looking for Reakit (v1), check out the v1 branch.


Installation

npm:

npm i ariakit

Yarn:

yarn add ariakit

Usage

import { createRoot } from "react-dom/client";
import {
  Button,
  Dialog,
  DialogHeading,
  DialogDescription,
  useDialogState,
} from "ariakit";

function App() {
  const dialog = useDialogState();
  return (
    <>
      <Button onClick={dialog.toggle}>Open dialog</Button>
      <Dialog state={dialog}>
        <DialogHeading>Welcome</DialogHeading>
        <DialogDescription>Welcome to Reakit!</DialogDescription>
      </Dialog>
    </>
  );
}

createRoot(document.getElementById("root")).render(<App />);

Contributing

See [v2] Examples and follow the instructions on the contributing guide.