update deprecated lifecycle methods#97
Conversation
…ate to componentDidUpdate
|
seeing some issues, will investigate and reopen |
|
Ok, I figured out what was going on and dealt with it. I moved I also added all the build artifacts to the |
|
Thanks for this! I'll try to review it early next week as I'm travelling at the moment :) |
|
hey @nicolaskruchten, any update on this? we'd love to see this merged and released so we don't need to use an internal fork... |
|
just for reference, which versions of React is this meant to be compatible with? |
|
Here's the official notice from the React team on the migration path away from the deprecated lifecycle methods ( The warnings started showing up in |
|
OK, cool, but then how far back are these changes meant to stay compatible? Will this still work with React 15? 14? etc :) |
|
As far as I can tell from a cursory look at the React CHANGELOG, this should work with all older versions of React, as the only thing I'm doing here is moving to |
|
OK, this looks great, thanks so much for the PR :) It kind of seems like this whole |
|
🎉 |
Super naive approach - I basically switched
componentWillMounttocomponentDidMountandcomponentWillUpdatetocomponentDidUpdate.componentDidUpdatereceivesprevPropsinstead of
nextProps, so I also changedthis.materializeInput(nextProps.data)tothis.materializeInput(this.props.data).npm run test:jestpasses, butnpm run testfails at the prettier stage.FWIW there's still a
componentWillMountand acomponentWillUpdateinexamples/App.jsxbut I didn't want to muck with that...