umijs / umi

A framework in react community ✨
https://umijs.org
MIT License
15.39k stars 2.65k forks source link

升级 umi-build-dev 的依赖 #3097

Closed atzcl closed 4 years ago

atzcl commented 5 years ago

相关环境信息


希望能把 umi-build-dev dependencies 中的 react-routereact-router-dom 版本给升级一下,以便解决以下警告

Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://fb.me/react-async-component-lifecycle-hooks 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: Route, Router, Switch

或者增加类似 umi-plugin-react/plugins/antd 的处理

如果项目中有 antd 或者 antd-mobile 依赖,则优先使用项目中的依赖
v2codes commented 5 years ago

Umi 版本:2.9.5 Node 版本: v10.15.3 操作系统:windows Project:app

Warning: componentWillMount has been renamed, and is not recommended for use. See https://fb.me/react-async-component-lifecycle-hooks for details ... Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://fb.me/react-async-component-lifecycle-hooks for details.

stale[bot] commented 4 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

sorrycc commented 4 years ago

已升级。