diff --git a/content/blog/2020-02-26-react-v16.13.0.md b/content/blog/2020-02-26-react-v16.13.0.md
index 4fb5340426..66bc079577 100644
--- a/content/blog/2020-02-26-react-v16.13.0.md
+++ b/content/blog/2020-02-26-react-v16.13.0.md
@@ -5,25 +5,25 @@ redirect_from:
- "blog/2020/03/02/react-v16.13.0.html"
---
-Today we are releasing React 16.13.0. It contains bugfixes and new deprecation warnings to help prepare for a future major release.
+今天我们发布了 React 16.13.0。此版本修复了部分 bug 并添加了新的弃用警告,以助力接下来的主要版本。
-## New Warnings {#new-warnings}
+## 新的警告 {#new-warnings}
-### Warnings for some updates during render {#warnings-for-some-updates-during-render}
+### Render 期间更新的警告 {#warnings-for-some-updates-during-render}
-A React component should not cause side effects in other components during rendering.
+React 组件不应在 render 期间对其他组件产生副作用。
-It is supported to call `setState` during render, but [only for *the same component*](/docs/hooks-faq.html#how-do-i-implement-getderivedstatefromprops). If you call `setState` during a render on a different component, you will now see a warning:
+在 render 期间调用 `setState` 是被支持的,但是 [仅仅适用于*同一个组件*](/docs/hooks-faq.html#how-do-i-implement-getderivedstatefromprops)。 如果你在另一个组件 render 期间调用 `setState`,现在你将会看到一条警告。
```
Warning: Cannot update a component from inside the function body of a different component.
```
-**This warning will help you find application bugs caused by unintentional state changes.** In the rare case that you intentionally want to change the state of another component as a result of rendering, you can wrap the `setState` call into `useEffect`.
+**这些警告将会帮助你找到应用中由意外的状态改变引起的 bug。** 在极少数情况下,由于渲染,你有意要更改另一个组件的状态,你可以将 `setState` 调用包装为 `useEffect`。
-### Warnings for conflicting style rules {#warnings-for-conflicting-style-rules}
+### 冲突的样式规则警告 {#warnings-for-conflicting-style-rules}
-When dynamically applying a `style` that contains longhand and shorthand versions of CSS properties, particular combinations of updates can cause inconsistent styling. For example:
+当动态地应用包含了全写和简写的 `style` 版本的 CSS 属性时,特定的更新组合可能会导致样式不一致。例如:
```js
```
-You might expect this `
` to always have a red background, no matter the value of `toggle`. However, on alternating the value of `toggle` between `true` and `false`, the background color start as `red`, then alternates between `transparent` and `blue`, [as you can see in this demo](https://codesandbox.io/s/suspicious-sunset-g3jub).
+你可能期待这个 `
` 总是拥有红色背景,不论 `toggle` 的值是什么。然而,在 `true` 和 `false`之间交替使用`toggle`时,背景色开始是 `red`,然后在 `transparent` 和 `blue`之间交替, [正如你能在这个 demo 中看到的](https://codesandbox.io/s/suspicious-sunset-g3jub)。
-**React now detects conflicting style rules and logs a warning.** To fix the issue, don't mix shorthand and longhand versions of the same CSS property in the `style` prop.
+**React 现在检测到冲突的样式规则并打印出警告。**要解决此问题,请不要在 `style` 属性中混合使用同一CSS属性的简写和全写版本。
-### Warnings for some deprecated string refs {#warnings-for-some-deprecated-string-refs}
+### 某些废弃字符串 ref 的警告 {#warnings-for-some-deprecated-string-refs}
-[String Refs is an old legacy API](/docs/refs-and-the-dom.html#legacy-api-string-refs) which is discouraged and is going to be deprecated in the future:
+[字符串 ref 是过时的 API](/docs/refs-and-the-dom.html#legacy-api-string-refs) 这是不可取的,将来将被弃用:
```js
```
-(Don't confuse String Refs with refs in general, which **remain fully supported**.)
+(不要将字符串 ref 与一般的 ref 混淆,后者**仍然完全受支持**。)
-In the future, we will provide an automated script (a "codemod") to migrate away from String Refs. However, some rare cases can't be migrated automatically. This release adds a new warning **only for those cases** in advance of the deprecation.
+在将来,我们将提供一个自动脚本(“codemod”),以从字符串 ref 中迁移。然而,一些罕见的案例不能自动迁移。此版本在弃用之前添加了一个新的警告**仅适用于那些情况**。
-For example, it will fire if you use String Refs together with the Render Prop pattern:
+例如,如果将字符串 ref 与 Render Prop 模式一起使用,则它将触发:
```jsx
class ClassWithRenderProp extends React.Component {
@@ -73,9 +73,9 @@ class ClassParent extends React.Component {
}
```
-Code like this often indicates bugs. (You might expect the ref to be available on `ClassParent`, but instead it gets placed on `ClassWithRenderProp`).
+这样的代码通常暗含 bug。(你可能希望 ref 在 `ClassParent` 上可用,但是它被放在 `ClassWithRenderProp` 上)。
-**You most likely don't have code like this**. If you do and it is intentional, convert it to [`React.createRef()`](/docs/refs-and-the-dom.html#creating-refs) instead:
+**你很可能没有这样的代码**。如果是有意为之,请将其转换为 [`React.createRef()`](/docs/refs-and-the-dom.html#creating-refs):
```jsx
class ClassWithRenderProp extends React.Component {
@@ -101,109 +101,109 @@ class ClassParent extends React.Component {
> Note
>
-> To see this warning, you need to have the [babel-plugin-transform-react-jsx-self](https://babeljs.io/docs/en/babel-plugin-transform-react-jsx-self) installed in your Babel plugins. It must _only_ be enabled in development mode.
+> 要查看此警告,你需要在你的 Babel plugins 中安装 [babel-plugin-transform-react-jsx-self](https://babeljs.io/docs/en/babel-plugin-transform-react-jsx-self)。它必须 _仅仅_ 在开发模式下启用。
>
-> If you use Create React App or have the "react" preset with Babel 7+, you already have this plugin installed by default.
+> 如果你使用 Create React App 或者用 babel 7+ 的 React preset,那么默认情况下已经安装了这个插件。
-### Deprecating `React.createFactory` {#deprecating-reactcreatefactory}
+### 弃用 `React.createFactory` {#deprecating-reactcreatefactory}
-[`React.createFactory`](/docs/react-api.html#createfactory) is a legacy helper for creating React elements. This release adds a deprecation warning to the method. It will be removed in a future major version.
+[`React.createFactory`](/docs/react-api.html#createfactory)为 React 创建一个帮助器元素。此版本向该方法添加了一个弃用警告。它将在未来的主要版本中删除。
-Replace usages of `React.createFactory` with regular JSX. Alternately, you can copy and paste this one-line helper or publish it as a library:
+把 `React.createFactory` 替换为普通的 JSX 。或者可以复制并粘贴此单行辅助对象或将其发布为库:
```jsx
let createFactory = type => React.createElement.bind(null, type);
```
-It does exactly the same thing.
+它的作用完全相同。
-### Deprecating `ReactDOM.unstable_createPortal` in favor of `ReactDOM.createPortal` {#deprecating-reactdomunstable_createportal-in-favor-of-reactdomcreateportal}
+### 弃用 `ReactDOM.unstable_createPortal` 推荐 `ReactDOM.createPortal`{#deprecating-reactdomunstable_createportal-in-favor-of-reactdomcreateportal}
-When React 16 was released, `createPortal` became an officially supported API.
+当 React 16 发布时,`createPortal` 成为一个官方支持的 API。
-However, we kept `unstable_createPortal` as a supported alias to keep the few libraries that adopted it working. We are now deprecating the unstable alias. Use `createPortal` directly instead of `unstable_createPortal`. It has exactly the same signature.
+但是,我们保留了 `unstable_createPortal` 作为受支持的别名,以使采用它的少数库正常工作。我们现在反对使用 unstable 别名。直接使用 `createPortal` 而不是 `unstable_createPortal`。它有完全相同的签名。
-## Other Improvements {#other-improvements}
+## 其他改进 {#other-improvements}
-### Component stacks in hydration warnings {#component-stacks-in-hydration-warnings}
+### Hydration 过程中组件堆栈的警告 {#component-stacks-in-hydration-warnings}
-React adds component stacks to its development warnings, enabling developers to isolate bugs and debug their programs. This release adds component stacks to a number of development warnings that didn't previously have them. As an example, consider this hydration warning from the previous versions:
+React 将组件堆栈添加到其开发警告中,使开发人员能够隔离 bug 并调试他们的程序。此版本将组件堆栈添加到许多以前没有的开发警告中。举个例子,考虑一下以前版本中的 hydration 警告:
-
+
-While it's pointing out an error with the code, it's not clear where the error exists, and what to do next. This release adds a component stack to this warning, which makes it look like this:
+虽然它指出了代码中的一个错误,但不清楚错误在哪里存在,以及下一步该怎么做。此版本向此警告添加了一个组件堆栈,使其看起来如下所示:
-
+
-This makes it clear where the problem is, and lets you locate and fix the bug faster.
+这样可以清楚地看出问题所在,并让你更快地找到并修复错误。
-### Notable bugfixes {#notable-bugfixes}
+### 值得注意的错误修复 {#notable-bugfixes}
-This release contains a few other notable improvements:
+此版本包含其他一些值得注意的改进:
-- In Strict Development Mode, React calls lifecycle methods twice to flush out any possible unwanted side effects. This release adds that behaviour to `shouldComponentUpdate`. This shouldn't affect most code, unless you have side effects in `shouldComponentUpdate`. To fix this, move the code with side effects into `componentDidUpdate`.
+- 在严格的开发模式下,React 调用生命周期方法两次,以清除任何可能不需要的副作用。此版本将此行为添加到 `shouldComponentUpdate` 中。这不会影响大多数代码,除非在 `shouldComponentUpdate` 中有副作用。要解决此问题,请将具有副作用的代码移到 `componentDidUpdate` 中。
-- In Strict Development Mode, the warnings for usage of the legacy context API didn't include the stack for the component that triggered the warning. This release adds the missing stack to the warning.
+- 在严格开发模式下,使用遗留上下文 API 的警告不包括触发警告的组件堆栈。此版本将丢失的堆栈添加到警告中。
-- `onMouseEnter` now doesn't trigger on disabled `