idyll-lang/idyll

React lifecycle warning

Open

#711 创建于 2021年3月10日

在 GitHub 查看
 (0 评论) (0 反应) (0 负责人)JavaScript (1,977 star) (97 fork)batch import
ComponentsGood First PRRough EdgesRuntimehelp wanted

描述

Describe the bug Some components depend on React lifecycle methods that are being deprecated, see this warning:

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.\n

To Reproduce Create the default idyll article and look at terminal and JS console.

Expected behavior There are no warnings from React. I believe the idyll-document component relies on this method, as well as several components in idyll-components, including at least table, maybe others.

贡献者指南