Why React 16?
-
Better Error Handling. Right now, we wrap all of our component lifecycle methods in a "TryCatch" which is very resource intensive. React 16 gives us a new lifecycle method called componentDidCatch, which will effectively handle it the same way, but in a much more efficient manner. Link to new Error Handling
-
Better ways to render to dom elements not contained in component tree. Link To Info On "Portals". This is particularly useful for our "MapBubble" components
Things we need to do to upgrade to react 16 (could be more....):
- change global Map to c3dMapInterface. Find and replace all "Map." calls to "c3dMapInterface"
- remove hammerjs (depreciated), breaking in react 16
- remove createclass/proptypes - set as React.CreateClass = 'react-create-class' etc
- remove or rewrite react json table (depreciated), breaking in react 16
- make sure the browsers support Map and Set es6 types.