|
|
|
|
|
by tmanderson
5018 days ago
|
|
What's the deal with these posts? First the one from Facebook and now this one? If it's too hard for you to differentiate between a scroll and a touch, there's about 210923423234 libraries out there that can make that differentiation for you. |
|
You encounter difficulties such as:
* Different behavior across platforms (and risking uncanny valley responses if you don't duplicate it; particularly around scrolling)
* When the browser provides hooks into the underlying native code, the current event structure can't satisfy. For example, `-webkit-overflow-scrolling: touch` fires scroll events erratically on iOS and fails to update the scroll position between them.
* Fun "bugs" such as iOS Safari's annoying behavior of popping down the nav bar when you tap any anchor that has a href attribute - regardless of whether you intercept and cancel the events in either phase.
It's a matter of finding a balance between abstracting platforms and simply exposing their underlying mechanics. I'm not sure which side should win there.