7 ms·
Vibration API
- lwansbrough 5y agoPretty sure this API has been around for 8+ years and is likely at risk of deprecation. No, nobody used it, no it didn’t destroy the internet.
- tomcooks 5y agoNobody used it because it didn't work on most browsers.
- jeroenhd 5y agoIt works on Chrome, so that's most of the world's smartphones. Desktop support is obviously lacking, though you might be able to write an extension to forward vibrations to an attached games controller? Luckily, all the fancy web devs use iPhones so they probably don't even know about features like these, which helps in them not getting abused to hell. I've seen it used twice, once for physical feedback when using hassio (really nice) and once with one of those shitty scam ads (really awful). I was surprised that there wasn't a permission prompt for this API.
- IshKebab 5y agoWasn't the API actively abandoned already because it was only use by ads?
- deleted 5y ago[deleted]
- usrbinbash 5y agoI really hope this is based on a per-page user-given permission, same as access to audio/video capturing... Because if it isn't, any piece of adware code that loads onto the phone, would be able to run the tiny rotational-unbalance based mechanism within the phone for however long and in whatever fashion it sees fit. As if phone batteries didn't run down fast enough already...
- sp332 5y agoIf you click the small down-arrows on the Browser Compatibility chart, you can see the details about each browser that supports it. Most of them require a "user gesture", which is not as good as asking permission IMO but better than nothing. Firefox for Android used to ask permission, but for the last two years it just doesn't support this at all.
- pmontra 5y agoThere is a bug report for that. It's not been moving at all since it was opened https://github.com/mozilla-mobile/fenix/issues/2371 https://github.com/mozilla-mobile/fenix/issues/2371
- henearkr 5y agoI wanted to try it out and... there is no easy way to execute JS on an Android phone with Chrome, unlike on a laptop.
- Orphis 5y agoUse websites like JSFiddle & co is probably the way to go.
- vghaisas 5y agoHere's what I used to test it: https://googlechrome.github.io/samples/vibration/ https://googlechrome.github.io/samples/vibration/
- DrSiemer 5y agoHere's a library that has some effects to test as well: https://www.hapticsjs.org/ https://www.hapticsjs.org/ Looks like the vibration on phones only has a single strength setting, unlike those in gamepads.
- 2Gkashmiri 5y agolook. i get it. the problem is, EVERYONE starts abusing this left and right. remember notifications? i have it set to off by default because every news, every blog every publication wants me to turn on notifications for them only because of "breaking news" and other BS. go and see how chrome does it. its on by default and imo people are tricked into accepting those willy nilly. the result? i know people whose right side is littered with "offers" and "breaking news" and "see your horoscope". the worst part, i have had the time to help them get this shit off their computers and it is tiring. you have to disable each and every website one by one in the notifications, its like they don't want you to try. sure there is a general disable button but what if you want to disable all but one? have chromium developers heard about "checkbox and bulk actions"? https://www.howtogeek.com/725208/how-to-turn-off-pop-up-notifications-in-google-chrome/ https://www.howtogeek.com/725208/how-to-turn-off-pop-up-noti...
- daguava 5y agoThe only time I've seen this functionality used IRL is when an ad network hijacks the browser and takes you to a scare/infection tab on mobile. Take this out back and put it down next to the blink tag and chained alerts without auto dismissal.
- akersten 5y agoOr just put it behind a permission prompt and quit ruining all the cool features of the web for the rest of us
- daguava 5y agoI cannot think of a single time I want my phone to start vibrating in a web context outside of a very deep game integration.
- legerdemain 5y ago"Very deep"... is that subtle innuendo?
- daguava 5y agoNo. It isn't. And this isn't the place for that. Edit: I was thinking of simulation gaming, such as racing (forced feedback, hitting the wall), Fishing (fish on the line, rumble as forced feedback, etc)
- legerdemain 5y agoThis is 100% the place for that. On the XBox Live Indie Games marketplace, the top-selling game was always a "scalp massager" game (or "game") of some sort.
- mechanical_bear 5y agoI think previous poster is saying this is not really the place for titillating innuendo, or low effort jokes about such, which I’d tend to agree.
- mmwelt 5y agoWould be useful for this: https://busysimulator.com/ https://busysimulator.com/ Except that there's no support for the vibration API on Firefox for Android.
- tosh 5y agoI recently tried Xbox game streaming in the browser and it works better than I expected. The only thing missing is haptic feedback. Are there games in the browser or streaming services that support haptic feedback?
- k__ 5y agoWrote a bomberman clone for the browser once and wanted to habe some rumble for the explosions. Turned out, the game controller APIs doesn't support controller vibrations.
- brainzap 5y agoCan this be used with my lovense? jk
- h2odragon 5y agomissed integration opportunity? https://buttplug.io/ https://buttplug.io/
- qdot76367 5y agoFun fact: I was a developer at Mozilla when this API was announced, and was slated to possibly work on it, for Obvious Reasons.