5

We have a specific issue with events in react, which is related to different event types being available on different devices and browsers. Currently, we have to attach multiple events on each component to fill the gap, such as onMouseMove, onTouchMove, etc.

The new PointerEvents are supposed to solve this, but they are not available in older browsers, which means we cannot use them.

Is it possible to somehow create our own event type, which we attach to our react components, which handles this logic in the background?

<Element onCustomEvent={...} />

Thanks!

Firas Dib
  • 2,743
  • 19
  • 38
  • Did you have a look at [this](https://stackoverflow.com/questions/21951734/react-js-custom-events-for-communicating-with-parent-nodes)? – ShaH Sep 14 '18 at 09:02
  • 1
    @ShaH yes: none of them do what I want. They are attaching events in lifecycles, and/or using custom event services. I want to tap into the synthetic events in react. – Firas Dib Sep 14 '18 at 10:16

0 Answers0