[BREAKGLASS] Append-only mirror of github.com/bluewallet/react-native-true-sheet
Go to file
2025-12-12 03:35:22 +08:00
.github fix(ios): use __typeof instead of typeof in TrueSheetBlurView (#253) 2025-11-29 23:04:38 +08:00
.yarn fix(ios): rename to newPresentingViewController to avoid UIKit collision 2025-11-24 13:54:37 +08:00
.zed Feat: Fabric (#211) 2025-11-23 14:54:19 +08:00
android fix: interpolated index and detent for single detent (#297) 2025-12-09 22:18:30 +08:00
common/cpp/react/renderer/components/TrueSheetSpec refactor(cpp): use yoga namespace for StyleSizeLength (#260) 2025-12-01 22:28:49 +08:00
docs feat: add web support (#302) 2025-12-11 06:38:13 +08:00
example chore: extend root tsconfig in expo example and fix eslint ignore 2025-12-12 03:35:22 +08:00
ios fix: interpolated index and detent for single detent (#297) 2025-12-09 22:18:30 +08:00
scripts chore: pretty clean script 2025-12-12 03:23:55 +08:00
src refactor: reorganize examples with shared package (#306) 2025-12-12 03:08:20 +08:00
.clang-format Feat: Fabric (#211) 2025-11-23 14:54:19 +08:00
.editorconfig chore: initial commit 2024-03-17 05:43:05 +08:00
.gitattributes chore: initial commit 2024-03-17 05:43:05 +08:00
.gitignore refactor: reorganize examples with shared package (#306) 2025-12-12 03:08:20 +08:00
.nvmrc Feat: Fabric (#211) 2025-11-23 14:54:19 +08:00
.prettierignore chore: update prettier 2025-03-06 05:45:39 +08:00
.watchmanconfig chore: initial commit 2024-03-17 05:43:05 +08:00
.yarnrc.yml Feat: Fabric (#211) 2025-11-23 14:54:19 +08:00
AGENTS.md refactor: reorganize examples with shared package (#306) 2025-12-12 03:08:20 +08:00
babel.config.js Feat: Fabric (#211) 2025-11-23 14:54:19 +08:00
CODE_OF_CONDUCT.md chore: initial commit 2024-03-17 05:43:05 +08:00
CONTRIBUTING.md fix: background improvements (#214) 2025-11-24 17:17:34 +08:00
eslint.config.mjs chore: extend root tsconfig in expo example and fix eslint ignore 2025-12-12 03:35:22 +08:00
jest.setup.js Feat: Fabric (#211) 2025-11-23 14:54:19 +08:00
lefthook.yml Feat: Fabric (#211) 2025-11-23 14:54:19 +08:00
LICENSE chore: support RN 78 (#160) 2025-03-08 12:31:41 +08:00
package.json refactor: reorganize examples with shared package (#306) 2025-12-12 03:08:20 +08:00
react-native.config.js feat: move Fabric state wrapper to host view (#230) 2025-11-26 03:32:22 +08:00
README.md docs: update README 2025-12-01 08:45:45 +08:00
RNTrueSheet.podspec feat: handle container layout natively via Fabric state (#220) 2025-11-25 10:30:31 +08:00
tsconfig.build.json refactor: reorganize examples with shared package (#306) 2025-12-12 03:08:20 +08:00
tsconfig.json feat: add sheet navigator for react-navigation integration (#279) 2025-12-06 14:32:55 +08:00
turbo.json refactor: reorganize examples with shared package (#306) 2025-12-12 03:08:20 +08:00
yarn.lock refactor: reorganize examples with shared package (#306) 2025-12-12 03:08:20 +08:00

React Native True Sheet

CI NPM Downloads

Note

🎉 Version 3.0 is here! Completely rebuilt for Fabric with new features like automatic ScrollView detection, native headers/footers, sheet stacking, and more. Read the announcement

The true native bottom sheet experience for your React Native Apps. 💩

React Native True Sheet - IOSReact Native True Sheet - Android

Features

  • Powered by Fabric - Built on React Native's new architecture for maximum performance
  • 🚀 Native - Implemented in the native realm
  • 🎯 Type-safe - Full TypeScript support with Codegen-generated native interfaces
  • Accessible - Native accessibility and screen reader support out of the box
  • 🔄 Flexible API - Use imperative methods or lifecycle events
  • 🪟 Liquid Glass - iOS 26+ Liquid Glass support out of the box. Featured in Expo Blog

Installation

Important

Version 3.0+ requires React Native's New Architecture (Fabric) For the old architecture, use version 2.x. See the Migration Guide for upgrading.

Prerequisites

  • React Native >= 0.76 (Expo SDK 52+)
  • New Architecture enabled (default in RN 0.76+)

Expo

npx expo install @lodev09/react-native-true-sheet

Bare React Native

yarn add @lodev09/react-native-true-sheet
cd ios && pod install

Documentation

Usage

import { TrueSheet } from "@lodev09/react-native-true-sheet"

export const App = () => {
  const sheet = useRef<TrueSheet>(null)

  // Present the sheet ✅
  const present = async () => {
    await sheet.current?.present()
    console.log('horray! sheet has been presented 💩')
  }

  // Dismiss the sheet ✅
  const dismiss = async () => {
    await sheet.current?.dismiss()
    console.log('Bye bye 👋')
  }

  return (
    <View>
      <Button onPress={present} title="Present" />
      <TrueSheet
        ref={sheet}
        detents={['auto', 1]}
      >
        <Button onPress={dismiss} title="Dismiss" />
      </TrueSheet>
    </View>
  )
}

Testing

TrueSheet includes built-in Jest mocks for easy testing. Simply mock the package in your tests:

jest.mock('@lodev09/react-native-true-sheet');

All methods (present, dismiss, resize) are mocked as Jest functions, allowing you to test your components without native dependencies.

Full Testing Guide

Contributing

See the contributing guide to learn how to contribute to the repository and the development workflow.

License

MIT


Made with ❤️ by @lodev09