AlloyFinger icon indicating copy to clipboard operation
AlloyFinger copied to clipboard

AlloyFinger在react 16.2.0出现Warning

Open warjiang opened this issue 8 years ago • 3 comments

Warning: This synthetic event is reused for performance reasons. If you're seeing this, you're adding a new property in the synthetic event object. The property is never released. See https://fb.me/react-event-pooling for more information.

warjiang avatar Dec 07 '17 06:12 warjiang

这个Warning解决了吗,还是用了一个新的库 兄弟

Xpig4432xyx avatar Dec 14 '17 01:12 Xpig4432xyx

在_handleTouchStart,_handleTouchMove,_hadnleTouchEnd 方法里加上 evt.persist();

ecafe8 avatar Dec 21 '17 07:12 ecafe8

这个库里面一些事件会异步触发,此时react会回收evt对象,如果访问evt就会出现warning,建议调用event.persist()

loadingwyn avatar Jun 09 '18 12:06 loadingwyn