Haptics gives touch feedback: impact() with a Light, Medium or Heavy style, notification() for success, warning and error patterns, selectionStart()/selectionChanged() for pickers, and vibrate() for a plain buzz. Its manifest merges the VIBRATE permission, granted at install:
export async function buzz() {
await Haptics.impact({ style: ImpactStyle.Medium });
await Haptics.vibrate({ duration: 300 });
return show('haptics', 'impact MEDIUM, vibrate 300 ms');
}An emulator has no motor, but Android's vibrator service records every request:
adb -s emulator-5558 shell dumpsys vibrator_manager | grep booknest | tail -2 | cut -d'|' -f3,4,12 cancelled_superseded | duration: 14ms | played: [Step=0ms(amplitude=0.00),Step=43ms(amplitu
de=0.71)]
finished | duration: 315ms | played: Step=300ms(amplitude=1.00)The impact was a 43 ms step at 71% amplitude, and it was cut short after 14 ms: impact() resolves as soon as the request is queued, so the vibrate() that followed superseded it. Space haptic calls apart, or give each gesture one effect. Use them sparingly, for confirmations such as adding to the cart. On the web the plugin falls back to navigator.vibrate, which browsers on iOS do not implement.