UNPKG

@gorhom/bottom-sheet

Version:

A performant interactive bottom sheet with fully configurable options 🚀

13 lines (9 loc) • 338 B
import { useContext } from 'react'; import { BottomSheetInternalContext } from '../contexts/internal'; export const useBottomSheetInternal = () => { const context = useContext(BottomSheetInternalContext); if (context === null) { throw "'useBottomSheetInternal' cannot be used out of the BottomSheet!"; } return context; };