Skip to content

Universal SheetNative sheets for React Native, Expo and web

Bottom sheets, modals, alerts, toasts and popovers with stacking, snap points and full design control. One API on iOS, Android and the browser.

Phones showing a bottom sheet, a center modal and a toast

Install โ€‹

sh
npm install react-native-universal-sheet
cd ios && pod install
sh
yarn add react-native-universal-sheet
cd ios && pod install
sh
npx expo install react-native-universal-sheet
npx expo prebuild
npx expo run:ios   # or: npx expo run:android

See Installation for requirements, Expo and web setup.

Thirty-second example โ€‹

tsx
import {Button} from 'react-native';
import {NativeSheetProvider, useNativeSheet} from 'react-native-universal-sheet';

export default function App() {
  return (
    <NativeSheetProvider>
      <Home />
    </NativeSheetProvider>
  );
}

function Home() {
  const sheet = useNativeSheet();
  return (
    <Button
      title="Open filters"
      onPress={() =>
        sheet.present({
          id: 'filters',
          content: <Filters />,
          snapPoints: ['50%', '90%'],
        })
      }
    />
  );
}

What it looks like โ€‹

Bottom sheet
Center modal
Alert
Side drawer
Toast
Popover

These are placement diagrams. See Sheet types for all 23 and Platform support for what each platform draws today.

Early release (0.1.0)

The TypeScript API and the web renderer are complete and unit-tested. The native iOS and Android code has not yet been verified on a device, and on native every variant is currently presented as a bottom sheet. Read Status & roadmap before using this in production.

Released under the MIT License.