JakeSidSmith / react-fastclick

Fast Touch Events for React
https://www.npmjs.com/package/react-fastclick
MIT License
487 stars 41 forks source link

[Feature Request] Auto disable on updated browsers #35

Open romulof opened 8 years ago

romulof commented 8 years ago

Chrome 32+ already disables click delay if <meta name="viewport" content="width=device-width"> has width <= device-width.

Other browsers have support for CSS touch-action, so this simple CSS would be enough:

a[href], button {
    touch-action: manipulation;
}

(please apply auto-prefixer later)

More info here: http://www.telerik.com/blogs/what-exactly-is.....-the-300ms-click-delay

JakeSidSmith commented 7 years ago

In #42 which I'll be releasing soon (with a couple of other small changes), you'll be able to choose whether to initialize react-fastclick or not yourself. Would that solve this issue for you?