Is there a recommended way to support gestures in Elm? In Javascript there are nice libraries (HammerJS for example) that offer high level gesture primitives. I'm relatively new to Elm but as far as I can tell:
(a) There are no higher level touch/gesture libraries written natively in Elm (the `Touch` package was discontinued in 0.17 (quite alarming if you care about gestures), https://github.com/knledg/touch-events is just a super thin wrapper around touch event listeners). (b) There isn't a clean way to "fall back to JS" in the case of touch libraries because these libraries' APIs involve attaching directly to DOM nodes. This causes problems because the virtual DOM is pure (and opaque). It doesn't have "mount"/"unmount" lifecycle events like React does so you can't just pass DOM nodes out to JS. I'd be super interested to hear about any practical experience with this especially in a production environment. I've seen several references to this class of problem, but can't find a good solution. Given that several companies use Elm in production I'd have expected somebody to have had to deal with gestures by now. Elm is absolute heaven compared to JS but the lack of high level gesture primitives (and the recent removal of `Touch`) makes it difficult to commit to if you plan on having non-trivial support for mobile (unless you want to write your own gesture support in Elm). -- You received this message because you are subscribed to the Google Groups "Elm Discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
