Skip to content

Commit 94890b4

Browse files
committed
refactor: update haptics utility to conditionally enable feedback based on platform
1 parent bd7ed5f commit 94890b4

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/utils/haptics.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,13 @@ import { Platform } from 'react-native';
66
*
77
* Determines whether to use haptic feedback.
88
*
9-
* Haptic communication is a highly effective form of nonverbal communication in native applications.
9+
* Haptic feedback provides a physical response to user interactions,
10+
* enhancing the user experience in native applications. It is commonly
11+
* used to signify actions such as clicks, selections, or the display of a toast message
1012
*
11-
* It is for example used to communicate clicks, selections, or the apperance of a toast message.
13+
* Note: iOS devices produce more subtle haptic feedback compared to Android devices. It is now only used on iOS devices by default
1214
*/
13-
const USE_HAPTICS = true;
15+
const USE_HAPTICS = Platform.OS === 'ios';
1416

1517
export const HapticFeedback = {
1618
impactLight: 'impactLight',

0 commit comments

Comments
 (0)