That’s all we can say right now.
The method being used has been deprecated in the latest version of the React Framework and may be removed in the future version. It is recommended to look for an alternative for this to fix this issue.
Here are some deprecated lifecycle methods since v16.9.0
:
componentWillMount
componentWillReceiveProps
componentWillUpdate
// Example 1
React.render(<MyComponent />, root);
// Example 2
React.unmountComponentAtNode(root);
// Example 3
React.findDOMNode(this.refs.foo);
// Example 4
React.renderToString(<MyComponent />);
// Example 5
React.renderToStaticMarkup(<MyComponent />);
// Example 6
const propTypes = {
foo: PropTypes.bar,
};
// Example 7
// old lifecycles (since React 16.9)
componentWillMount() { }
componentWillReceiveProps() { }
componentWillUpdate() { }
// Example 1
ReactDOM.render(<MyComponent />, root);
// Example 2
ReactDOM.unmountComponentAtNode(root)
// Example 3
ReactDOM.findDOMNode(this.refs.foo)
// Example 4
ReactDOMServer.renderToString(<MyComponent />);
// Example 5
ReactDOMServer.renderToStaticMarkup(<MyComponent />);
// Example 6
import { PropTypes } from 'prop-types';
// Example 7
UNSAFE_componentWillMount() { }
UNSAFE_componentWillReceiveProps() { }
UNSAFE_componentWillUpdate() { }