plone / volto

React-based frontend for the Plone Content Management System
https://demo.plone.org/
MIT License
447 stars 607 forks source link

DateInput is using old code #1810

Open tiberiuichim opened 4 years ago

tiberiuichim commented 4 years ago

Warning in developer console:

> react-dom.development.js:88 Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://fb.me/react-unsafe-component-lifecycles for details.

* Move data fetching code or side effects to componentDidUpdate.
* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state
* Rename componentWillReceiveProps to UNSAFE_componentWillReceiveProps to suppress this warning in non-strict mode. In React 17.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run `npx react-codemod rename-unsafe-lifecycles` in your project source folder.

Please update the following components: DateInput
tiberiuichim commented 4 years ago

Some other warning, related to draft-js-plugins editor:

react-dom.development.js:88 Warning: componentWillUpdate has been renamed, and is not recommended for use. See https://fb.me/react-unsafe-component-lifecycles for details.

* Move data fetching code or side effects to componentDidUpdate.
* Rename componentWillUpdate to UNSAFE_componentWillUpdate to suppress this warning in non-strict mode. In React 17.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run `npx react-codemod rename-unsafe-lifecycles` in your project source folder.

Please update the following components: DraftEditor

I think the draftjs editor also needs updates, there's been some action here: https://github.com/draft-js-plugins/draft-js-plugins/issues/1393