logoalt Hacker News

outlore11/07/20241 replyview on HN

perhaps off topic: for many months i’ve been thinking about creating tactile buttons. are there any APIs to produce vibration in the phone via the browser? i’d like a way to create a vibration response curve when toggling a switch. i’d like to feel the friction and resistance like a real-life switch. is this within the realm of possibility with current browser APIs?


Replies

shepherdjerred11/07/2024

https://developer.mozilla.org/en-US/docs/Web/API/Vibration_A...

Not supported on iOS

show 1 reply