From 3967f12f3d2434327500311e4a0b823a6f80f06c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BA=8C=E8=B4=A7=E6=9C=BA=E5=99=A8=E4=BA=BA?= Date: Tue, 28 Apr 2020 12:19:15 +0800 Subject: [PATCH] docs: Add mutable data warning (#23696) --- docs/react/migration-v4.en-US.md | 1 + docs/react/migration-v4.zh-CN.md | 1 + 2 files changed, 2 insertions(+) diff --git a/docs/react/migration-v4.en-US.md b/docs/react/migration-v4.en-US.md index 0b7952cee0..f076acc81f 100644 --- a/docs/react/migration-v4.en-US.md +++ b/docs/react/migration-v4.en-US.md @@ -32,6 +32,7 @@ This document will help you upgrade from antd `3.x` version to antd `4.x` versio - The minimum supported version of IE is IE 11. - The minimum supported version of React is React 16.9, and some components have started to refactor using hooks. + - Internal using `useMemo` for performance, do not use mutable data as props. #### Remove deprecated API diff --git a/docs/react/migration-v4.zh-CN.md b/docs/react/migration-v4.zh-CN.md index db744a32d5..04f36234d1 100644 --- a/docs/react/migration-v4.zh-CN.md +++ b/docs/react/migration-v4.zh-CN.md @@ -32,6 +32,7 @@ title: 从 v3 到 v4 - IE 最低支持版本为 IE 11。 - React 最低支持版本为 React 16.9,部分组件开始使用 hooks 进行重构。 + - 重构通过 `useMemo` 进行性能优化,请勿使用 mutable data 作为参数。 #### 移除废弃的 API