Skip to content

Commit e875df9

Browse files
Merge branch 'main' into main
2 parents c7e372c + 1b22ad2 commit e875df9

33 files changed

+715
-707
lines changed

content/blog/2018-10-23-react-v-16-6.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ Refer to the documentation for [detailed installation instructions](/docs/instal
119119
## Changelog {#changelog}
120120

121121
### React {#react}
122-
122+
123123
* Add `React.memo()` as an alternative to `PureComponent` for functions. ([@acdlite](https://github.com/acdlite) in [#13748](https://github.com/facebook/react/pull/13748))
124124
* Add `React.lazy()` for code splitting components. ([@acdlite](https://github.com/acdlite) in [#13885](https://github.com/facebook/react/pull/13885))
125125
* `React.StrictMode` now warns about legacy context API. ([@bvaughn](https://github.com/bvaughn) in [#13760](https://github.com/facebook/react/pull/13760))

content/community/conferences.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
---
22
id: conferences
3-
title: Conferences
3+
title: Các hội nghị
44
layout: community
55
sectionid: community
66
permalink: community/conferences.html
77
redirect_from:
88
- "docs/conferences.html"
99
---
1010

11-
Do you know of a local React.js conference? Add it here! (Please keep the list chronological)
11+
Bạn có biết về hội nghị React.js ở địa phương hay khu vực của bạn không? Hãy thêm nó vào đây! (Và vui lòng giữ nguyên danh sách theo thứ tự thời gian).
1212

1313
## Upcoming Conferences {#upcoming-conferences}
1414

content/community/examples.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
id: examples
3-
title: Example Projects
3+
title: Các dự án mẫu
44
layout: community
55
sectionid: community
66
permalink: community/examples.html
@@ -10,7 +10,7 @@ Có rất nhiều dự án mẫu được tạo bởi cộng đồng React. Chú
1010

1111
Nếu bạn thêm một dự án, hãy cam kết cập nhật nó với các phiên bản React mới nhất.
1212

13-
## Ví dụ nhỏ {#small-examples}
13+
## Các dự án mẫu cỡ nhỏ {#small-examples}
1414

1515
* **[Calculator](https://github.com/ahfarmer/calculator)** Triển khai máy tính iOS xây dựng bằng React
1616
* **[Emoji Search](https://github.com/ahfarmer/emoji-search)** Ứng dụng React tìm kiếm biểu tượng cảm xúc

content/community/meetups.md

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,15 @@ Bạn đã có React.js meetup tại quốc gia của bạn chưa? Thêm nó và
1515
* [Buenos Aires](https://www.meetup.com/es/React-en-Buenos-Aires)
1616
* [Rosario](https://www.meetup.com/es/reactrosario)
1717

18-
## Australia {#australia}
18+
## Úc {#australia}
1919
* [Brisbane](https://www.meetup.com/reactbris/)
2020
* [Melbourne](https://www.meetup.com/React-Melbourne/)
2121
* [Sydney](https://www.meetup.com/React-Sydney/)
2222

23-
## Austria {#austria}
23+
## Áo {#austria}
2424
* [Vienna](https://www.meetup.com/Vienna-ReactJS-Meetup/)
2525

26-
## Belgium {#belgium}
26+
## Bỉ {#belgium}
2727
* [Belgium](https://www.meetup.com/ReactJS-Belgium/)
2828

2929
## Brazil {#brazil}
@@ -53,28 +53,28 @@ Bạn đã có React.js meetup tại quốc gia của bạn chưa? Thêm nó và
5353
## Chile {#chile}
5454
* [Santiago](https://www.meetup.com/es-ES/react-santiago/)
5555

56-
## China {#china}
56+
## Trung Quốc {#china}
5757
* [Beijing](https://www.meetup.com/Beijing-ReactJS-Meetup/)
5858

5959
## Colombia {#colombia}
6060
* [Bogotá](https://www.meetup.com/meetup-group-iHIeHykY/)
6161
* [Medellin](https://www.meetup.com/React-Medellin/)
6262
* [Cali](https://www.meetup.com/reactcali/)
6363

64-
## Denmark {#denmark}
64+
## Đan Mạch {#denmark}
6565
* [Aalborg](https://www.meetup.com/Aalborg-React-React-Native-Meetup/)
6666
* [Aarhus](https://www.meetup.com/Aarhus-ReactJS-Meetup/)
6767

68-
## England (UK) {#england-uk}
68+
## Anh (Vương Quốc Anh) {#england-uk}
6969
* [Manchester](https://www.meetup.com/Manchester-React-User-Group/)
7070
* [React.JS Girls London](https://www.meetup.com/ReactJS-Girls-London/)
7171

72-
## France {#france}
72+
## Pháp {#france}
7373
* [Nantes](https://www.meetup.com/React-Nantes/)
7474
* [Lille](https://www.meetup.com/ReactBeerLille/)
7575
* [Paris](https://www.meetup.com/ReactJS-Paris/)
7676

77-
## Germany {#germany}
77+
## Đức {#germany}
7878
* [Cologne](https://www.meetup.com/React-Cologne/)
7979
* [Düsseldorf](https://www.meetup.com/de-DE/ReactJS-Meetup-Dusseldorf/)
8080
* [Hamburg](https://www.meetup.com/Hamburg-React-js-Meetup/)
@@ -83,14 +83,14 @@ Bạn đã có React.js meetup tại quốc gia của bạn chưa? Thêm nó và
8383
* [Munich](https://www.meetup.com/ReactJS-Meetup-Munich/)
8484
* [React Berlin](https://www.meetup.com/React-Open-Source/)
8585

86-
## Greece {#greece}
86+
## Hy Lạp {#greece}
8787
* [Athens](https://www.meetup.com/React-To-React-Athens-MeetUp/)
8888
* [Thessaloniki](https://www.meetup.com/Thessaloniki-ReactJS-Meetup/)
8989

9090
## Hungary {#hungary}
9191
* [Budapest](https://www.meetup.com/React-Budapest/)
9292

93-
## India {#india}
93+
## Ấn Độ {#india}
9494
* [Bangalore](https://www.meetup.com/ReactJS-Bangalore/)
9595
* [Bangalore](https://www.meetup.com/React-Native-Bangalore-Meetup)
9696
* [Chandigarh](https://www.meetup.com/Chandigarh-React-Developers/)
@@ -108,20 +108,20 @@ Bạn đã có React.js meetup tại quốc gia của bạn chưa? Thêm nó và
108108
## Israel {#israel}
109109
* [Tel Aviv](https://www.meetup.com/ReactJS-Israel/)
110110

111-
## Italy {#italy}
111+
## Ý {#italy}
112112
* [Milan](https://www.meetup.com/React-JS-Milano/)
113113

114114
## Malaysia {#malaysia}
115115
* [Kuala Lumpur](https://www.kl-react.com/)
116116
* [Penang](https://www.facebook.com/groups/reactpenang/)
117117

118-
## Netherlands {#netherlands}
118+
## Hà Lan {#netherlands}
119119
* [Amsterdam](https://www.meetup.com/React-Amsterdam/)
120120

121121
## New Zealand {#new-zealand}
122122
* [Wellington](https://www.meetup.com/React-Wellington/)
123123

124-
## Norway {#norway}
124+
## Na Uy {#norway}
125125
* [Norway](https://reactjs-norway.webflow.io/)
126126
* [Oslo](https://www.meetup.com/ReactJS-Oslo-Meetup/)
127127

@@ -139,35 +139,35 @@ Bạn đã có React.js meetup tại quốc gia của bạn chưa? Thêm nó và
139139
* [Manila](https://www.meetup.com/reactjs-developers-manila/)
140140
* [Manila - ReactJS PH](https://www.meetup.com/ReactJS-Philippines/)
141141

142-
## Poland {#poland}
142+
## Ba Lan {#poland}
143143
* [Warsaw](https://www.meetup.com/React-js-Warsaw/)
144144

145-
## Portugal {#portugal}
145+
## Bồ Đào Nha {#portugal}
146146
* [Lisbon](https://www.meetup.com/JavaScript-Lisbon/)
147147

148-
## Scotland (UK) {#scotland-uk}
148+
## Scotland (Vương Quốc Anh) {#scotland-uk}
149149
* [Edinburgh](https://www.meetup.com/React-Scotland/)
150150

151151
## Singapore {#singapore}
152152
* [Singapore - React Knowledgeable](https://reactknowledgeable.org/)
153153

154-
## Spain {#spain}
154+
## Tây Ban Nha {#spain}
155155
* [Barcelona](https://www.meetup.com/ReactJS-Barcelona/)
156156
* [Canarias](https://www.meetup.com/React-Canarias/)
157157

158-
## Sweden {#sweden}
158+
## Thụy Điển {#sweden}
159159
* [Goteborg](https://www.meetup.com/ReactJS-Goteborg/)
160160

161-
## Switzerland {#switzerland}
161+
## Thụy Sỹ {#switzerland}
162162
* [Zurich](https://www.meetup.com/Zurich-ReactJS-Meetup/)
163163

164-
## Turkey {#turkey}
164+
## Thổ Nhĩ Kỳ {#turkey}
165165
* [Istanbul](https://kommunity.com/reactjs-istanbul)
166166

167-
## Ukraine {#ukraine}
167+
## Ukraina {#ukraine}
168168
* [Kyiv](https://www.meetup.com/Kyiv-ReactJS-Meetup)
169169

170-
## US {#us}
170+
## Mỹ {#us}
171171
* [Ann Arbor, MI - ReactJS](https://www.meetup.com/AnnArbor-jsx/)
172172
* [Atlanta, GA - ReactJS](https://www.meetup.com/React-ATL/)
173173
* [Austin, TX - ReactJS](https://www.meetup.com/ReactJS-Austin-Meetup/)

content/community/nav.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
11
- title: Nguồn cộng đồng
22
items:
33
- id: support
4-
title: Support
4+
title: Hỗ trợ
55
- id: team
66
title: Team
77
- id: courses
8-
title: Courses
8+
title: Các khóa học
99
- id: examples
10-
title: Examples
10+
title: Các dự án mẫu
1111
- id: meetups
12-
title: Meetups
12+
title: Các cuộc gặp gỡ
1313
- id: conferences
14-
title: Conferences
14+
title: Các hội nghị
1515
- id: articles
16-
title: Articles
16+
title: Bài viết
1717
- id: podcasts
1818
title: Podcasts
1919
- id: videos

content/community/support.md

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -8,28 +8,28 @@ redirect_from:
88
- "support.html"
99
---
1010

11-
React has a community of millions of developers.
11+
React có một cộng đồng hàng triệu lập trình viên.
1212

13-
On this page we've listed some React-related communities that you can be a part of; see the other pages in this section for additional online and in-person learning materials.
13+
Trên trang này chúng tôi đã liệt kê ra một số cộng đồng liên quan đến React mà bạn có thể tham gia; xem các trang khác trong phần này để biết thêm tài liệu học online và trực tiếp.
1414

15-
Before participating in React's communities, [please read our Code of Conduct](https://github.com/facebook/react/blob/main/CODE_OF_CONDUCT.md). We have adopted the [Contributor Covenant](https://www.contributor-covenant.org/) and we expect that all community members adhere to the guidelines within.
15+
Trước khi tham gia vào cộng đồng React, [vui lòng đọc Quy tắc ứng xử của chúng tôi](https://github.com/facebook/react/blob/main/CODE_OF_CONDUCT.md). Chúng tôi đã áp dụng [Giao ước cộng tác viên](https://www.contributor-covenant.org/) và chúng tôi hi vọng các thành viên trong cộng đồng sẽ tuân thủ các qui tắc.
1616

1717
## Stack Overflow {#stack-overflow}
1818

19-
Stack Overflow is a popular forum to ask code-level questions or if you're stuck with a specific error. Read through the [existing questions](https://stackoverflow.com/questions/tagged/reactjs) tagged with **reactjs** or [ask your own](https://stackoverflow.com/questions/ask?tags=reactjs)!
19+
Stack Overflow là một diễn đàn nổi tiếng để đặt các câu hỏi về code hoặc nếu bạn gặp một lỗi cụ thể. Đọc qua [câu hỏi hiện có](https://stackoverflow.com/questions/tagged/reactjs) được gắn thẻ **reactjs** hoặc [câu hỏi của riêng bạn](https://stackoverflow.com/questions/ask?tags=reactjs)!
2020

21-
## Popular Discussion Forums {#popular-discussion-forums}
21+
## Diễn đàn thảo luận phổ biến {#popular-discussion-forums}
2222

23-
There are many online forums which are a great place for discussion about best practices and application architecture as well as the future of React. If you have an answerable code-level question, Stack Overflow is usually a better fit.
23+
Có rất nhiều diễn đàn online là nơi tuyệt vời để thảo luận về phương pháp hay nhất và kiến trúc ứng dụng cũng như tương lai của React. Nếu bạn có một câu hỏi về code có thể trả lời được, Stack Overflow là một nơi phù hợp.
2424

25-
Each community consists of many thousands of React users.
25+
Mỗi cộng đồng bao gồm hàng nghìn người dùng React.
2626

27-
* [DEV's React community](https://dev.to/t/react)
28-
* [Hashnode's React community](https://hashnode.com/n/reactjs)
29-
* [Reactiflux online chat](https://discord.gg/reactiflux)
30-
* [Reddit's React community](https://www.reddit.com/r/reactjs/)
31-
* [Spectrum's React community](https://spectrum.chat/react)
27+
* [Cộng đồng React của DEV](https://dev.to/t/react)
28+
* [Cộng đồng React của Hashnode](https://hashnode.com/n/reactjs)
29+
* [Trò chuyện online với Reactiflux](https://discord.gg/reactiflux)
30+
* [Cộng đồng React của Reddit](https://www.reddit.com/r/reactjs/)
31+
* [Cộng đồng React của Spectrum](https://spectrum.chat/react)
3232

33-
## News {#news}
33+
## Tin tức {#news}
3434

35-
For the latest news about React, [follow **@reactjs** on Twitter](https://twitter.com/reactjs) and the [official React blog](/blog/) on this website.
35+
Để biết thêm tin tức mới nhất về React, [theo dõi **@reactjs** trên Twitter](https://twitter.com/reactjs) [blog chính thức của React](/blog/) trên trang này.

content/docs/add-react-to-a-website.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
id: add-react-to-a-website
3-
title: Add React to a Website
3+
title: Thêm React vào một Website
44
permalink: docs/add-react-to-a-website.html
55
redirect_from:
66
- "docs/add-react-to-an-existing-app.html"

content/docs/addons-pure-render-mixin.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,22 +6,22 @@ layout: docs
66
category: Add-Ons
77
---
88

9-
> Note:
9+
> Lưu ý:
1010
>
11-
> `PureRenderMixin` is a legacy add-on. Use [`React.PureComponent`](/docs/react-api.html#reactpurecomponent) instead.
11+
> `PureRenderMixin` được kế thừa từ add-on. Sử dụng [`React.PureComponent`](/docs/react-api.html#reactpurecomponent) thay thế.
1212
1313
**Importing**
1414

1515
```javascript
1616
import PureRenderMixin from 'react-addons-pure-render-mixin'; // ES6
17-
var PureRenderMixin = require('react-addons-pure-render-mixin'); // ES5 with npm
17+
var PureRenderMixin = require('react-addons-pure-render-mixin'); // ES5 với npm
1818
```
1919

20-
## Overview {#overview}
20+
## Tổng quát {#overview}
2121

22-
If your React component's render function renders the same result given the same props and state, you can use this mixin for a performance boost in some cases.
22+
Nếu function render của React component của bạn hiển thị cùng một kết quả với cùng prop và state, bạn có thể sử dụng mixin để tăng hiệu suất trong một số trường hợp.
2323

24-
Example:
24+
Ví dụ:
2525

2626
```js
2727
const createReactClass = require('create-react-class');
@@ -35,10 +35,10 @@ createReactClass({
3535
});
3636
```
3737

38-
Under the hood, the mixin implements [shouldComponentUpdate](/docs/component-specs.html#updating-shouldcomponentupdate), in which it compares the current props and state with the next ones and returns `false` if the equalities pass.
38+
Xem xét một cách kỹ lưỡng, mixin thực hiện [shouldComponentUpdate](/docs/component-specs.html#updating-shouldcomponentupdate), trong đó nó so sánh prop và state hiện tại với những cái tiếp theo và trả về `false` nếu chúng bằng nhau.
3939

40-
> Note:
40+
> Lưu ý:
4141
>
42-
> This only shallowly compares the objects. If these contain complex data structures, it may produce false-negatives for deeper differences. Only mix into components which have simple props and state, or use `forceUpdate()` when you know deep data structures have changed. Or, consider using [immutable objects](https://facebook.github.io/immutable-js/) to facilitate fast comparisons of nested data.
42+
> Đây chỉ là so sánh nông với các object. Nếu object chứa cấu trúc dữ liệu phức tạp, nó có thể tạo ra các trường hợp sai đối với sự khác nhau sâu trong nhiều cấp của object. Chỉ được dùng đối với component có prop và state đơn giản, hoặc dùng `forceUpdate()` khi bạn biết cấu trúc dữ liệu sâu bên trong đã thay đổi. Có thể cân nhắc sử dụng [immutable objects](https://facebook.github.io/immutable-js/) để dễ dàng so sánh các dữ liệu lồng nhau.
4343
>
44-
> Furthermore, `shouldComponentUpdate` skips updates for the whole component subtree. Make sure all the children components are also "pure".
44+
> Hơn nữa, `shouldComponentUpdate` bỏ qua cập nhật toàn bộ các component con. Hãy đảm bảo rằng tất cả các component con cũng là "pure".

content/docs/addons-shallow-compare.md

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6,24 +6,26 @@ layout: docs
66
category: Reference
77
---
88

9-
> Note:
9+
> Lưu ý:
1010
>
11-
> `shallowCompare` is a legacy add-on. Use [`React.memo`](/docs/react-api.html#reactmemo) or [`React.PureComponent`](/docs/react-api.html#reactpurecomponent) instead.
11+
> `shallowCompare` được kế thừa từ add-on. Sử dụng [`React.memo`](/docs/react-api.html#reactmemo) hoặc [`React.PureComponent`](/docs/react-api.html#reactpurecomponent) thay thế.
1212
1313
**Importing**
1414

1515
```javascript
1616
import shallowCompare from 'react-addons-shallow-compare'; // ES6
17-
var shallowCompare = require('react-addons-shallow-compare'); // ES5 with npm
17+
var shallowCompare = require('react-addons-shallow-compare'); // ES5 với npm
1818
```
1919

20-
## Overview {#overview}
20+
## Tổng quát {#overview}
2121

22-
Before [`React.PureComponent`](/docs/react-api.html#reactpurecomponent) was introduced, `shallowCompare` was commonly used to achieve the same functionality as [`PureRenderMixin`](pure-render-mixin.html) while using ES6 classes with React.
2322

24-
If your React component's render function is "pure" (in other words, it renders the same result given the same props and state), you can use this helper function for a performance boost in some cases.
23+
Trước khi [`React.PureComponent`](/docs/react-api.html#reactpurecomponent) được giới thiệu, `shallowCompare` thường được sử dụng có chức năng tương tự như [`PureRenderMixin`](pure-render-mixin.html) trong khi sử dụng các lớp ES6 với React.
2524

26-
Example:
25+
Nếu render function của React component là "thuần" (nói một cách khác, nó trả về cùng một kết quả với cùng props và state), bạn có thể dùng helper function để tăng cường hiệu suất trong một số trường hợp.
26+
27+
28+
Ví dụ:
2729

2830
```js
2931
export class SampleComponent extends React.Component {
@@ -37,8 +39,9 @@ export class SampleComponent extends React.Component {
3739
}
3840
```
3941

40-
`shallowCompare` performs a shallow equality check on the current `props` and `nextProps` objects as well as the current `state` and `nextState` objects.
41-
It does this by iterating on the keys of the objects being compared and returning true when the values of a key in each object are not strictly equal.
42+
`shallowCompare` thực hiện kiểm tra shallow equality ở các đối tượng `props``nextProps` hiện tại cũng như các đối tượng `state``nextState` hiện tại. Nó thực hiện điều này bằng cách thực hiện lặp đi lặp lại trên các khóa của đối tượng được so sánh và trả về true khi các giá trị của khóa ở mỗi đối tượng không hoàn toàn bằng nhau.
43+
44+
`shallowCompare` trả về `true` nếu phép so sánh shallow cho props hoặc state thất bại và component sẽ được cập nhật.
45+
46+
`shallowCompare` trả về `false` nếu phép so sánh shallow cho props hoặc state thành công và component không cần cập nhật.
4247

43-
`shallowCompare` returns `true` if the shallow comparison for props or state fails and therefore the component should update.
44-
`shallowCompare` returns `false` if the shallow comparison for props and state both pass and therefore the component does not need to update.

content/docs/faq-functions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,7 @@ class Searchbox extends React.Component {
282282
<input
283283
type="text"
284284
onChange={this.handleChange}
285-
placeholder="Search..."
285+
placeholder="Tìm kiếm..."
286286
defaultValue={this.props.value}
287287
/>
288288
);

0 commit comments

Comments
 (0)