Vaul
vaul
Drawer component for React.
Utilities
react
drawer
dialog
modal
vaul
Utilities
javascript
npm
frontend
open source
Stars
8.6k
Weekly
21M
Open issues
163
Bundle
~15 kB
Installation
npm install vaulCode example
import { Drawer } from "vaul";
export function Example() {
return (
<Drawer.Root>
<Drawer.Trigger>Open</Drawer.Trigger>
<Drawer.Portal>
<Drawer.Overlay />
<Drawer.Content>
<p>Drawer content</p>
</Drawer.Content>
</Drawer.Portal>
</Drawer.Root>
);
}Pros & cons
Pros
- Actively maintained by Emil Kowalski
- 21M weekly downloads. Battle tested
- First-class TypeScript definitions
- MIT licensed
Considerations
- Adds roughly ~15 kB to your bundle
- Needs client-only rendering in SSR frameworks
- Not supported in React Native
- 163 open issues on GitHub