ten1seven / what-input

A global utility for tracking the current input method (mouse/pointer, keyboard or touch).
https://ten1seven.github.io/what-input
MIT License
1.35k stars 89 forks source link

Add passive to touchstart event #67

Closed thebuilder closed 6 years ago

thebuilder commented 6 years ago

Building on #63 - Expanded it to also be added to the touchstart event per recommendation. Google recommends adding it to all wheel, mousewheel, touchstart, and touchmove events.

https://developers.google.com/web/tools/lighthouse/audits/passive-event-listeners https://github.com/WICG/EventListenerOptions/blob/gh-pages/explainer.md

ten1seven commented 6 years ago

Excellent @thebuilder, thank you!