-
Notifications
You must be signed in to change notification settings - Fork 782
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Updated componentWillMount to componentDidMount #220
base: master
Are you sure you want to change the base?
Conversation
src/index.js
Outdated
@@ -213,7 +213,7 @@ function createLoadableComponent(loadFn, options) { | |||
}); | |||
} | |||
|
|||
componentWillUnmount() { | |||
componentDidUnmount() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As I understand, componentWillUnmount
wasn't deprecated, only componentWillMount
.
BTW componentDidUnmount
non-existent method
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay , Sir I will change it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sir i have changed the method back to componentWillUnmount
Also interested in this change 🎉 |
Any plan on merging this PR? and release date? |
Can someone help merge this PR and publish the lib :) |
Seems like a very small change for this codebase, would love to see it merged and published soon! |
Guys, I considered react-loadable has not been maintaining, please migrate to other package such as |
Anyone can merge this PR? I got same warning. |
same warning. any update? |
why this PR wont be merged? |
I don't mean to harp on this pull request but it's a one line change that has been open for 2 months with no update. Can we please have some communication for the cause of the hold up? Thanks! |
* upgrades to antd to v4 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800
* upgrades to antd to v4 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800
INSPIR-3203 * upgrades to antd to v4 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800
INSPIR-3203 * upgrades to antd to v4 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800
INSPIR-3203 * upgrades to antd to v4 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800
* upgrades to antd to v4 * fixes UX problems with date range picker: INSPIR-3203 * reduces bundle size by removing unnecessary icons: INSPIR-3228 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800
* upgrades to antd to v4 * fixes UX problems with date range picker: INSPIR-3203 * reduces bundle size by removing unnecessary icons: INSPIR-3228 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800
* upgrades to antd to v4 * fixes UX problems with date range picker: INSPIR-3203 * reduces bundle size by removing unnecessary icons: INSPIR-3228 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800
* upgrades to antd to v4 * fixes UX problems with date range picker: INSPIR-3203 * reduces bundle size by removing unnecessary icons: INSPIR-3228 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800
* upgrades to antd to v4 * fixes UX problems with date range picker: INSPIR-3203 * reduces bundle size by removing unnecessary icons: INSPIR-3228 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800
* upgrades to antd to v4 * fixes UX problems with date range picker: INSPIR-3203 * reduces bundle size by removing unnecessary icons: INSPIR-3228 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800
* upgrades to antd to v4 * fixes UX problems with date range picker: INSPIR-3203 * reduces bundle size by removing unnecessary icons: INSPIR-3228 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800
* upgrades to antd to v4 * fixes UX problems with date range picker: INSPIR-3203 * reduces bundle size by removing unnecessary icons: INSPIR-3228 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800
* upgrades to antd to v4 * fixes UX problems with date range picker: INSPIR-3203 * reduces bundle size by removing unnecessary icons: INSPIR-3228 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800 * `componentWillReceiveProps` warnings from `react-quill` zenoamaro/react-quill#549
* upgrades to antd to v4 * fixes UX problems with date range picker: INSPIR-3203 * reduces bundle size by removing unnecessary icons: INSPIR-3228 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800 * `componentWillReceiveProps` warnings from `react-quill` zenoamaro/react-quill#549
* upgrades to antd to v4 * fixes UX problems with date range picker: INSPIR-3203 * reduces bundle size by removing unnecessary icons: INSPIR-3228 * upgrades to react@16.13.10 * upgrades to react-router to v5 Unresolved: * `componentWillReceiveProps` warnings from `react-vis` uber/react-vis#1253 * search name space truncates some options like `conferen...` ant-design/ant-design#21754 * `componentWillMount` warnings from `react-helmet` nfl/react-helmet#413 * `componentWillMount` warnings from `react-loadable` jamiebuilds/react-loadable#220 * `Cannot update a component from inside the function body of a different component.` worning from `antd` ant-design/ant-design#21800 * `componentWillReceiveProps` warnings from `react-quill` zenoamaro/react-quill#549
Hi all, I put the fixed version with addition of build files in my github repo so you can change your npm package to this if you need a quick fix. should look like this in package.json:
|
@p0o it works, thanks. I cloned this repo, and found "yarn start" not work at all. |
@cnscorpions I think I built it with npm. |
So it is clear that we will be migrating off react-loadable at some point. I certainly understand the challenges of donating your time to an open source project. |
Suggestion: You can fork my repo up there into your github organization or publish your npm package if you need a more reliable solution. |
For anyone interested, here's my solution to get rid of the warning (React 16 + 17) and still get this working (client+SSR). |
I was using this in my project and i saw its using componentWillMount which will be deprected in the new version of react so i updated it with componentDidMount. To avoid deprecation and remove the warning