TouchBolocker - React Native component that helps blocking the user from interac...
source link: https://reactnativeexample.com/touchbolocker-react-native-component-that-helps-blocking-the-user-from-interacting-with-children-components/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
TouchBolocker - React Native component that helps blocking the user from interacting with children components
Apr 14, 2022
1 min read
react-native-touch-blocker
TouchBolocker is a React Native and React Native Web component that helps blocking the user from interacting with children components.
Install
npm install react-native-touch-blocker --save
yarn add react-native-touch-blocker
Test it online on Expo
Usage
<TouchBlocker> <Button title="Can't Touch This 😎" onPress={() => null} /> </TouchBlocker>
Props
Prop Default Type Description
enableTouchEvents false Boolean Allow children to receive touch events
The TouchBlocker component also supports React Native View Props.
GitHub
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK