Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Beta]:docs(cn): translation api reactdom done #662

Closed
wants to merge 6 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 13 additions & 11 deletions beta/src/pages/reference/reactdom.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
---
title: ReactDOM API
layout: API
translators:
- liu-jin-yi
---

<Intro>

The ReactDOM package lets you render React components on a webpage.
ReactDOM package 能够让你在页面上渲染 React 组件。

</Intro>

Typically, you will use ReactDOM at the top level of your app to display your components. You will either use it directly or a [framework](/learn/start-a-new-react-project#building-with-react-and-a-framework) may do it for you. Most of your components should *not* need to import this module.
通常情况下,你会在你的应用程序的顶层使用 ReactDOM 来展示你的组件。你要么直接使用它,要么让 [框架](/learn/start-a-new-react-project#building-with-react-and-a-framework) 为你所用。你的大部分组件应该 *不* 需要导入这个模块。

## Installation
## 安装

<PackageImport>

Expand All @@ -22,27 +24,27 @@ npm install react-dom
</TerminalBlock>

```js
// Importing a specific API:
// 如何引入一个特定的 API
import { render } from 'react-dom';

// Importing all APIs together:
// 如何将所有的 API 一起引入:
import * as ReactDOM from 'react';
```

</PackageImport>

You'll also need to install the same version of [React](/api/).
你还需要安装相同版本的 [React](/api/)

## Browser Support
## 浏览器支持

ReactDOM supports all popular browsers, including Internet Explorer 9 and above. [Some polyfills are required](http://todo%20link%20to%20js%20environment%20requirements/) for older browsers such as IE 9 and IE 10.
ReactDOM 支持所有流行的浏览器,包括 Internet Explorer 9 及以上。对于 IE 9 和 IE 10 等旧浏览器 [需要一些 polyfills](http://todo%20link%20to%20js%20environment%20requirements/)

## Exports
## 导出

<YouWillLearnCard title="render" path="/reference/render">

Renders a piece of JSX ("React element") into a browser DOM container node.
可以将一段 JSX (“React 元素”)渲染到浏览器 DOM 容器节点中。

</YouWillLearnCard>

This section is incomplete and is still being written!
本节内容不完整,仍在撰写中!