When the library is rendered I'm getting:
Warning: getInitialState was defined on t, a plain JavaScript class. This is only supported for classes created using React.createClass. Did you mean to define a state property instead?
me too
Also getting this issue after bumping versions from 0.41 -> 0.46
"react": "^15.4.2"
me too, how to solve it ?
This happens because getInitialState is defined, in datepicker.jsx at least. It is being used to set the state in the constructor so in this case there isn't an actual problem - ideally the check that React does would check whether getInitialState is called in the constructor and not generate this warning when it is.
The developers here could easily fix it by renaming getInitialState to something that React does not check for (even though the name is a perfect fit for what it does now).
For ES6 classes, getInitialState has been deprecated in favor of declaring an initial state object in the constructor: http://stackoverflow.com/a/33447222. We'll need to rewrite getInitialState to this new flavor.
What's the status on this? I don't see the change in master yet...?
Most helpful comment
What's the status on this? I don't see the change in master yet...?