mkuczera / react-native-haptic-feedback

React-Native Haptic Feedback for iOS with Android similar behaviour.
MIT License
847 stars 103 forks source link

Detect haptics? #58

Open jacdx opened 3 years ago

jacdx commented 3 years ago

Is there a way to detect if your device has haptics? Getting a persistent warning on Simulator when using this library which I would like to avoid.

mkuczera commented 3 years ago

Hi, sorry for the late reply. I will check to make the availability of haptics checkable.

In case of the yellow box warning message: this can also be ignored outside of this library: console.ignoredYellowBox = [''];

nickmcmillan commented 1 year ago

Possibly related; I'd like to offer the user the option to enable/disable haptics. But I'd only like to show this toggle in the UI if their device actually supports haptics.

So I'm wondering if there's currently a way to detect if the device supports haptics?