React
16.4 consists of mainly 2 things. First is the introduction of Pointer Events, and second is a fix to
the getDerivedStateFromProps
component life cycle event.
Pointer events are used to handle mouse and touch activity like hover, enter, leave etc. They are similar to jQuery mouse event handlers like mouseenter, mouseleave, mouseover etc. The difference between jQuery mouse events and React pointer events is that the Pointer events support both Mouse events and Touch events.
The following are the pointer events supported in React 16.4
onPointerDown
onPointerMove
onPointerUp
onPointerCancel
onGotPointerCapture
onLostPointerCapture
onPointerEnter
onPointerLeave
onPointerOver
onPointerOut
There is a change / bug fix in the getDerivedStateFromProps life cycle method. The getDerivedStateFromProps life cycle method will now get called each time the component gets rendered / re-renders, prior to React 16.4 the method was called only when the component was re-rendered by its parent and not when the component’s state changes due to setState, now it will get called in all cases.
Pointer events are used to handle mouse and touch activity like hover, enter, leave etc. They are similar to jQuery mouse event handlers like mouseenter, mouseleave, mouseover etc. The difference between jQuery mouse events and React pointer events is that the Pointer events support both Mouse events and Touch events.
The following are the pointer events supported in React 16.4
onPointerDown
onPointerMove
onPointerUp
onPointerCancel
onGotPointerCapture
onLostPointerCapture
onPointerEnter
onPointerLeave
onPointerOver
onPointerOut
There is a change / bug fix in the getDerivedStateFromProps life cycle method. The getDerivedStateFromProps life cycle method will now get called each time the component gets rendered / re-renders, prior to React 16.4 the method was called only when the component was re-rendered by its parent and not when the component’s state changes due to setState, now it will get called in all cases.
No comments:
Post a Comment