Skip to content

Commit 7a07441

Browse files
committed
resolve conflicts eef56ff
2 parents 801a940 + eef56ff commit 7a07441

16 files changed

+87
-73
lines changed

content/blog/2018-03-27-update-on-async-rendering.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ Here is an example of a component that uses the legacy `componentWillReceiveProp
134134

135135
Although the above code is not problematic in itself, the `componentWillReceiveProps` lifecycle is often mis-used in ways that _do_ present problems. Because of this, the method will be deprecated.
136136

137-
As of version 16.3, the recommended way to update `state` in response to `props` changes is with the new `static getDerivedStateFromProps` lifecycle. (That lifecycle is called when a component is created and each time it receives new props):
137+
As of version 16.3, the recommended way to update `state` in response to `props` changes is with the new `static getDerivedStateFromProps` lifecycle. It is called when a component is created and each time it re-renders due to changes to props or state:
138138
`embed:update-on-async-rendering/updating-state-from-props-after.js`
139139

140140
You may notice in the example above that `props.currentRow` is mirrored in state (as `state.lastRow`). This enables `getDerivedStateFromProps` to access the previous props value in the same way as is done in `componentWillReceiveProps`.

content/blog/2019-02-23-is-react-translated-yet.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ In the past, React community members have created unofficial translations for [C
2323

2424
If you would like to help out on a current translation, check out the [Languages](/languages) page and click on the "Contribute" link for your language.
2525

26-
Can't find your language? If you'd like to maintain your langauge's translation fork, follow the instructions in the [translation repo](https://github.com/reactjs/reactjs.org-translation#starting-a-new-translation)!
26+
Can't find your language? If you'd like to maintain your language's translation fork, follow the instructions in the [translation repo](https://github.com/reactjs/reactjs.org-translation#starting-a-new-translation)!
2727

2828
## Backstory {#backstory}
2929

@@ -39,7 +39,7 @@ This approach appealed to us for several reasons:
3939
* It encouraged active maintainers for each repo to ensure quality.
4040
* Contributors already understand GitHub as a platform and are motivated to contribute directly to the React organization.
4141

42-
We started of with an initial trial period of three languages: Spanish, Japanese, and Simplified Chinese. This allowed us to work out any kinks in our process and make sure future translations are set up for success. I wanted to give the translation teams freedom to choose whatever tools they felt comfortable with. The only requirement is a [checklist](https://github.com/reactjs/reactjs.org-translation/blob/master/PROGRESS.template.md) that outlines the order of importance for translating pages.
42+
We started off with an initial trial period of three languages: Spanish, Japanese, and Simplified Chinese. This allowed us to work out any kinks in our process and make sure future translations are set up for success. I wanted to give the translation teams freedom to choose whatever tools they felt comfortable with. The only requirement is a [checklist](https://github.com/reactjs/reactjs.org-translation/blob/master/PROGRESS.template.md) that outlines the order of importance for translating pages.
4343

4444
After the trial period, we were ready to accept more languages. I created [a script](https://github.com/reactjs/reactjs.org-translation/blob/master/scripts/create.js) to automate the creation of the new language repo, and a site, [Is React Translated Yet?](https://isreacttranslatedyet.com), to track progress on the different translations. We started *10* new translations on our first day alone!
4545

content/community/conferences.md

Lines changed: 35 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -12,36 +12,6 @@ Do you know of a local React.js conference? Add it here! (Please keep the list c
1212

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

15-
### ReactEurope 2019 {#reacteurope-2019}
16-
May 23-24, 2019 in Paris, France
17-
18-
[Website](https://www.react-europe.org) - [Twitter](https://twitter.com/ReactEurope) - [Facebook](https://www.facebook.com/ReactEurope) - [Videos](https://www.youtube.com/c/ReacteuropeOrgConf)
19-
20-
### React Conf Armenia 2019 {#react-conf-am-19}
21-
May 25, 2019 in Yerevan, Armenia
22-
23-
[Website](https://reactconf.am/) - [Twitter](https://twitter.com/ReactConfAM) - [Facebook](https://www.facebook.com/reactconf.am/) - [YouTube](https://www.youtube.com/c/JavaScriptConferenceArmenia) - [CFP](http://bit.ly/speakReact)
24-
25-
### ReactNext 2019 {#react-next-2019}
26-
June 11, 2019. Tel Aviv, Israel
27-
28-
[Website](https://react-next.com) - [Twitter](https://twitter.com/ReactNext) - [Videos](https://www.youtube.com/channel/UC3BT8hh3yTTYxbLQy_wbk2w)
29-
30-
### React Norway 2019 {#react-norway-2019}
31-
June 12, 2019. Larvik, Norway
32-
33-
[Website](https://reactnorway.com) - [Twitter](https://twitter.com/ReactNorway)
34-
35-
### React Loop 2019 {#react-loop-2019}
36-
June 21, 2019 Chicago, Illinois USA
37-
38-
[Website](https://reactloop.com) - [Twitter](https://twitter.com/ReactLoop)
39-
40-
### Chain React 2019 {#chain-react-2019}
41-
July 11-12, 2019. Portland, OR, USA.
42-
43-
[Website](https://infinite.red/ChainReactConf)
44-
4515
### React Rally 2019 {#react-rally-2019}
4616
August 22-23, 2019. Salt Lake City, USA.
4717

@@ -82,6 +52,11 @@ September 26-28, 2019 in Alicante, Spain
8252

8353
[Website](http://reactalicante.es/) - [Twitter](https://twitter.com/reactalicante) - [Facebook](https://www.facebook.com/ReactAlicante)
8454

55+
### React Conf 2019 {#react-conf-2019}
56+
October 24-25, 2019 in Henderson, Nevada USA
57+
58+
[Website](https://conf.reactjs.org/) - [Twitter](https://twitter.com/reactjs)
59+
8560
### React Advanced 2019 {#react-advanced-2019}
8661
October 25, 2019 in London, UK
8762

@@ -395,3 +370,33 @@ May 3, 2019 in London, UK
395370
May 11 in Sofia, Bulgaria
396371

397372
[Website](http://react-not-a-conf.com/) - [Twitter](https://twitter.com/reactnotaconf) - [Facebook](https://www.facebook.com/events/780891358936156)
373+
374+
### ReactEurope 2019 {#reacteurope-2019}
375+
May 23-24, 2019 in Paris, France
376+
377+
[Website](https://www.react-europe.org) - [Twitter](https://twitter.com/ReactEurope) - [Facebook](https://www.facebook.com/ReactEurope) - [Videos](https://www.youtube.com/c/ReacteuropeOrgConf)
378+
379+
### React Conf Armenia 2019 {#react-conf-am-19}
380+
May 25, 2019 in Yerevan, Armenia
381+
382+
[Website](https://reactconf.am/) - [Twitter](https://twitter.com/ReactConfAM) - [Facebook](https://www.facebook.com/reactconf.am/) - [YouTube](https://www.youtube.com/c/JavaScriptConferenceArmenia) - [CFP](http://bit.ly/speakReact)
383+
384+
### ReactNext 2019 {#react-next-2019}
385+
June 11, 2019. Tel Aviv, Israel
386+
387+
[Website](https://react-next.com) - [Twitter](https://twitter.com/ReactNext) - [Videos](https://www.youtube.com/channel/UC3BT8hh3yTTYxbLQy_wbk2w)
388+
389+
### React Norway 2019 {#react-norway-2019}
390+
June 12, 2019. Larvik, Norway
391+
392+
[Website](https://reactnorway.com) - [Twitter](https://twitter.com/ReactNorway)
393+
394+
### React Loop 2019 {#react-loop-2019}
395+
June 21, 2019 Chicago, Illinois USA
396+
397+
[Website](https://reactloop.com) - [Twitter](https://twitter.com/ReactLoop)
398+
399+
### Chain React 2019 {#chain-react-2019}
400+
July 11-12, 2019. Portland, OR, USA.
401+
402+
[Website](https://infinite.red/ChainReactConf)

content/community/courses.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ permalink: community/courses.html
2222

2323
- [Free React Bootcamp](https://tylermcginnis.com/free-react-bootcamp/) - Recordings from three days of a free online React bootcamp.
2424

25+
- [Scrimba: Learn React for free](https://scrimba.com/g/glearnreact) - 48 hands-on video tutorials building react apps.
26+
2527
## Paid Courses {#paid-courses}
2628

2729
- [Egghead.io](https://egghead.io/browse/frameworks/react) - Short instructional videos on React and many other topics.

content/community/meetups.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ Do you have a local React.js meetup? Add it here! (Please keep the list alphabet
5555
* [Düsseldorf](https://www.meetup.com/de-DE/ReactJS-Meetup-Dusseldorf/)
5656
* [Hamburg](https://www.meetup.com/Hamburg-React-js-Meetup/)
5757
* [Karlsruhe](https://www.meetup.com/react_ka/)
58+
* [Kiel](https://www.meetup.com/Kiel-React-Native-Meetup/)
5859
* [Munich](https://www.meetup.com/ReactJS-Meetup-Munich/)
5960
* [React Berlin](https://www.meetup.com/React-Berlin/)
6061
* [React.JS Girls Berlin](https://www.meetup.com/ReactJS-Girls-Berlin/)
@@ -69,6 +70,7 @@ Do you have a local React.js meetup? Add it here! (Please keep the list alphabet
6970
* [Bangalore](https://www.meetup.com/ReactJS-Bangalore/)
7071
* [Chennai](https://www.meetup.com/React-Chennai/)
7172
* [Delhi NCR](https://www.meetup.com/React-Delhi-NCR/)
73+
* [Jaipur](https://www.meetup.com/JaipurJS-Developer-Meetup/)
7274

7375
## Ireland {#ireland}
7476
* [Dublin](https://www.meetup.com/ReactJS-Dublin/)

content/community/tools-ui-components.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ permalink: community/ui-components.html
7272
## Fee Based Components {#fee-based-components}
7373

7474
* **[ag-Grid](https://www.ag-grid.com)** Advanced data grid / data table for React.
75+
* **[DevExtreme Reactive](https://devexpress.github.io/devextreme-reactive/react/)** High-performance plugin-based Data Grid, Scheduler and Chart components for Bootstrap and Material Design.
7576
* **[ExtReact components](https://www.sencha.com/products/extreact//)**: 115+ Ready-to-Use UI Components.
7677
* **[Grapecity Wijmo UI Components for React](https://www.grapecity.com/en/react/)**: Expand your React UI options with Wijmo’s complete collection of JavaScript components.
7778
* **[jQWidgets React components](https://www.jqwidgets.com/react/)**: Enterprise Ready 70+ UI Components.

content/docs/code-splitting.md

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -107,9 +107,7 @@ import("./math").then(math => {
107107

108108
> Примечание:
109109
>
110-
> Возможности `React.lazy` и задержки (suspense) пока недоступны для рендеринга на стороне сервера.
111-
> Если вам нужно разделение кода в серверном приложении, мы рекомендуем [Loadable Components](https://github.com/smooth-code/loadable-components).
112-
> У них есть хорошее [руководство по разделению бандла](https://github.com/smooth-code/loadable-components/blob/master/packages/server/README.md) с серверным рендерингом.
110+
> Возможности `React.lazy` и задержки (suspense) пока недоступны для рендеринга на стороне сервера. Если вам нужно разделение кода в серверном приложении, мы рекомендуем [Loadable Components](https://github.com/smooth-code/loadable-components). У них есть хорошее [руководство по разделению бандла](https://github.com/smooth-code/loadable-components/blob/master/packages/server/README.md) с серверным рендерингом.
113111
114112

115113
Функция `React.lazy` позволяет рендерить динамический импорт как обычный компонент.

content/docs/create-a-new-react-app.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ next: cdn-links.html
3939

4040
[Create React App](https://github.com/facebookincubator/create-react-app) – удобная среда для **изучения React** и лучший способ начать создание **нового [одностраничного](/docs/glossary.html#single-page-application) приложения** на React.
4141

42-
Инструмент настраивает среду для использования новейших возможностей JavaScript, оптимизирует приложение для продакшена и обеспечивает комфорт во время разработки. Вам понадобятся Node.js не ниже версии 6 и npm не ниже версии 5.2 на вашем компьютере. Для создания проекта выполните команды:
42+
Инструмент настраивает среду для использования новейших возможностей JavaScript, оптимизирует приложение для продакшена и обеспечивает комфорт во время разработки. Вам понадобятся Node.js не ниже версии 8.10 и npm не ниже версии 5.6 на вашем компьютере. Для создания проекта выполните команды:
4343

4444
```bash
4545
npx create-react-app my-app

content/docs/fragments.md

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ render() {
1818
}
1919
```
2020

21-
Также существует [сокращённая запись](#short-syntax), однако не все популярные инструменты поддерживают её.
21+
Также существует [сокращённая запись](#short-syntax).
2222

2323
## Мотивация {#motivation}
2424

@@ -113,8 +113,6 @@ class Columns extends React.Component {
113113

114114
Можно использовать `<></>` так же, как используется любой другой элемент. Однако такая запись не поддерживает ключи или атрибуты.
115115

116-
Обратите внимание, что **[большинство инструментов ещё не поддерживают сокращённую запись](/blog/2017/11/28/react-v16.2.0-fragment-support.html#support-for-fragment-syntax)**, поэтому можно явно указывать `<React.Fragment>`, пока не появится поддержка.
117-
118116
### Фрагменты с ключами {#keyed-fragments}
119117

120118
Фрагменты, объявленные с помощью `<React.Fragment>`, могут иметь ключи. Например, их можно использовать при создании списка определений, преобразовав коллекцию в массив фрагментов.

content/docs/hooks-faq.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ prev: hooks-reference.html
7070

7171
Обратите внимание, что **хуки будут доступны, только если все React-пакеты версии 16.8.0 или выше**. Хуки не будут работать, если вы, например, забыли обновить React DOM.
7272

73-
Поддержка хуков в React Native добавится в следующем стабильном релизе.
73+
React Native 0.59 и выше поддерживает хуки.
7474

7575
### Надо ли переписать все мои классовые компоненты? {#do-i-need-to-rewrite-all-my-class-components}
7676

@@ -621,7 +621,6 @@ function ProductPage({ productId }) {
621621
const json = await response.json();
622622
if (!ignore) setProduct(json);
623623
}
624-
625624
fetchProduct();
626625
return () => { ignore = true };
627626
}, [productId]);
@@ -678,6 +677,8 @@ function Counter() {
678677
}
679678
```
680679

680+
Пустой набор зависимостей `[]` означает, что эффект будет выполняться только один раз, когда компонент монтируется, а не при каждом повторном рендере. Проблема в том, что внутри обратного вызова `setInterval` значение `count` не изменяется, потому что мы создали замыкание со значением `count`, установленным в `0`, как это было при выполнении обратного вызова эффекта. Каждую секунду этот обратный вызов вызывает `setCount(0 + 1)`, поэтому счетчик никогда не превышает 1.
681+
681682
Если переписать список зависимостей как `[count]`, то баг будет устранён, но это приведёт к сбрасыванию интервала при каждом изменении. Такое поведение может быть нежелательно. Чтобы исправить это, мы можем применить [форму функционального обновления хука `setState`](/docs/hooks-reference.html#functional-updates), которая позволяет указать, *как* должно меняться состояние, не ссылаясь явно на *текущее* состояние:
682683

683684
```js{6,9}
@@ -697,6 +698,8 @@ function Counter() {
697698

698699
(Идентичность функции `setCount` гарантирована, поэтому её можно безопасно не включать в список зависимостей.)
699700

701+
Теперь обратный вызов `setInterval` выполняется один раз в секунду, но каждый раз, когда внутренний вызов `setCount` может использовать обновленное значение для `count` (называемое `c` в обратном вызове здесь.)
702+
700703
В более сложных случаях (например, когда одно состояние зависит от другого), попробуйте перенести логику обновления состояния из хука эффекта в хук [`useReducer`](/docs/hooks-reference.html#usereducer). [Эта статья](https://adamrackis.dev/state-and-use-reducer/) иллюстрирует пример того, как это сделать. **Идентичность функции `dispatch` из хука `useReducer` всегда стабильна** — даже если функция редюсера объявлена внутри компонента и считывает его пропсы.
701704

702705
В крайнем случае если вы хотите реализовать что-то наподобие `this` в классах, вы можете [использовать реф](/docs/hooks-faq.html#is-there-something-like-instance-variables), чтобы хранить в нём изменяемую переменную. Тогда можно писать и читать из него. Например:

content/docs/how-to-contribute.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,8 @@ React использует [семантическое версионирова
5050
У Facebook есть [программа Bug Bounty](https://www.facebook.com/whitehat/) для сообщения о багах безопасности. Пожалуйста, не публикуйте ишью о таких проблемах в открытом доступе. Если вы обнаружили дыру в безопасности React, зайдите на [эту страницу](https://www.facebook.com/whitehat/) и следуйте инструкциям.
5151

5252
### Наши контакты {#how-to-get-in-touch}
53-
5453
* IRC: [#reactjs на freenode](https://webchat.freenode.net/?channels=reactjs)
55-
* Форум: [discuss.reactjs.org](https://discuss.reactjs.org/)
54+
* [Форум](https://reactjs.org/community/support.html#popular-discussion-forums)
5655

5756
Кроме этого есть [сообщество пользователей React на платформе чатов Discord](https://www.reactiflux.com/). Туда вы также можете обратиться за помощью.
5857

0 commit comments

Comments
 (0)