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

docs(cn): translate content/docs/context.md into Chinese #87

Merged
merged 52 commits into from
Mar 9, 2019

Conversation

BetaMee
Copy link
Contributor

@BetaMee BetaMee commented Feb 11, 2019

No description provided.

@QC-L QC-L added the Pending Review 已翻译,待校对阶段 label Feb 12, 2019
Copy link
Member

@yuqingc yuqingc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

consume 的翻译需要和大家讨论,需要统一

@QC-L QC-L mentioned this pull request Feb 14, 2019
Yuqing Chen and others added 4 commits February 15, 2019 10:53
Co-Authored-By: BetaMee <gongxq95@gmail.com>
Co-Authored-By: BetaMee <gongxq95@gmail.com>
Co-Authored-By: BetaMee <gongxq95@gmail.com>
Co-Authored-By: BetaMee <gongxq95@gmail.com>
@netlify
Copy link

netlify bot commented Feb 15, 2019

Deploy preview for cn-reactjs ready!

Built with commit f684ef3

https://deploy-preview-87--cn-reactjs.netlify.com

Co-Authored-By: BetaMee <gongxq95@gmail.com>
@netlify
Copy link

netlify bot commented Feb 15, 2019

Deploy preview for cn-reactjs ready!

Built with commit 5814007

https://deploy-preview-87--cn-reactjs.netlify.com

@netlify
Copy link

netlify bot commented Feb 15, 2019

Deploy preview for cn-reactjs ready!

Built with commit 41756fa

https://deploy-preview-87--cn-reactjs.netlify.com

betamee and others added 6 commits February 15, 2019 11:06
Co-Authored-By: BetaMee <gongxq95@gmail.com>
Co-Authored-By: BetaMee <gongxq95@gmail.com>
Co-Authored-By: BetaMee <gongxq95@gmail.com>
Copy link
Member

@QC-L QC-L left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review 了一部分,晚点继续

@QC-L QC-L added Pending Modify 已校对,待修改阶段 and removed Pending Review 已翻译,待校对阶段 labels Feb 21, 2019
QC-L and others added 8 commits February 21, 2019 16:35
Co-Authored-By: BetaMee <gongxq95@gmail.com>
Co-Authored-By: BetaMee <gongxq95@gmail.com>
Co-Authored-By: BetaMee <gongxq95@gmail.com>
Co-Authored-By: BetaMee <gongxq95@gmail.com>
Co-Authored-By: BetaMee <gongxq95@gmail.com>
Co-Authored-By: BetaMee <gongxq95@gmail.com>
Co-Authored-By: BetaMee <gongxq95@gmail.com>
Co-Authored-By: BetaMee <gongxq95@gmail.com>
QC-L
QC-L previously approved these changes Feb 28, 2019
QC-L
QC-L previously approved these changes Mar 5, 2019
Copy link
Member

@hijiangtao hijiangtao left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

除 consume 译法需统一外无其他问题。

}
}
MyClass.contextType = MyContext;
```

The `contextType` property on a class can be assigned a Context object created by [`React.createContext()`](#reactcreatecontext). This lets you consume the nearest current value of that Context type using `this.context`. You can reference this in any of the lifecycle methods including the render function.
挂载在 class 上的 `contextType` 属性会被重赋值为一个由 [`React.createContext()`](#reactcreatecontext) 创建的 Context 对象。这能让你使用 `this.context` 来获取最近 Context 上的那个值。你可以在任何生命周期中访问到它,包括 render 函数中。
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

consume 在这里被译为获取

@@ -31,7 +31,7 @@ function Layout() {
);
}

// A component may consume multiple contexts
// 一个组件可能会调用多个 context
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

consume 在这里被译为调用

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

统一翻译成消费不好么,在事件模型里,不是有生产者/消费者模式么,也是用的这个词。使用/调用/获取都有对应的词了。

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@BetaMee 来讨论一下以便于快点merge啦

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@maicss “一个组件可能会消费多个 context”、“这能让你使用 this.context 来消费最近 Context 上的那个值。”

@QC-L QC-L added Pending Modify 已校对,待修改阶段 and removed Pending Re-Review 已修改,待审校阶段 labels Mar 7, 2019
Co-Authored-By: BetaMee <gongxq95@gmail.com>
@BetaMee BetaMee dismissed stale reviews from QC-L via 21b018f March 9, 2019 03:13
QC-L and others added 3 commits March 9, 2019 11:13
Co-Authored-By: BetaMee <gongxq95@gmail.com>
QC-L and others added 2 commits March 9, 2019 11:21
Co-Authored-By: BetaMee <gongxq95@gmail.com>
Co-Authored-By: BetaMee <gongxq95@gmail.com>
QC-L
QC-L previously approved these changes Mar 9, 2019
Copy link
Member

@QC-L QC-L left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@hijiangtao hijiangtao requested a review from QC-L March 9, 2019 06:17
@QC-L QC-L merged commit 04e7bb5 into reactjs:master Mar 9, 2019
@BetaMee BetaMee deleted the context branch March 9, 2019 16:33
OhIAmFine pushed a commit to OhIAmFine/zh-hans.reactjs.org that referenced this pull request May 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Pending Modify 已校对,待修改阶段
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants