Skip to content

Commit ea5c339

Browse files
Merge pull request #125 from reactjs/sync-c3c93e2a
Sync with reactjs.org @ c3c93e2
2 parents e7ec217 + 0b97a1e commit ea5c339

File tree

5 files changed

+7
-15
lines changed

5 files changed

+7
-15
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ The documentation is divided into several sections with a different tone and pur
5353
1. `git push my-fork-name the-name-of-my-branch`
5454
1. Go to the [reactjs.org repo](https://github.com/reactjs/reactjs.org) and you should see recently pushed branches.
5555
1. Follow GitHub's instructions.
56-
1. If possible, include screenshots of visual changes. A Netlify build will also be automatically created once you make your PR so other people can see your change.
56+
1. If possible, include screenshots of visual changes. A [Netlify](https://www.netlify.com/) build will also be automatically created once you make your PR so other people can see your change.
5757

5858
## Translation
5959

content/docs/code-splitting.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ console.log(add(16, 26)); // 42
4242
4343
If you're using [Create React App](https://create-react-app.dev/), [Next.js](https://nextjs.org/), [Gatsby](https://www.gatsbyjs.org/), or a similar tool, you will have a Webpack setup out of the box to bundle your app.
4444

45-
If you aren't, you'll need to setup bundling yourself. For example, see the [Installation](https://webpack.js.org/guides/installation/) and [Getting Started](https://webpack.js.org/guides/getting-started/) guides on the Webpack docs.
45+
If you aren't, you'll need to set up bundling yourself. For example, see the [Installation](https://webpack.js.org/guides/installation/) and [Getting Started](https://webpack.js.org/guides/getting-started/) guides on the Webpack docs.
4646

4747
## Code Splitting {#code-splitting}
4848

content/docs/concurrent-mode-adoption.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@ next: concurrent-mode-reference.html
2121
>
2222
>This documentation is aimed at early adopters and people who are curious. **If you're new to React, don't worry about these features** -- you don't need to learn them right now.
2323
24+
>Caution:
25+
>
26+
>All references below to "blocking mode" and `createBlockingRoot` are outdated and should be ignored.
27+
2428
</div>
2529

2630
- [Installation](#installation)

content/docs/concurrent-mode-reference.md

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@ This page is an API reference for the React [Concurrent Mode](/docs/concurrent-m
2828

2929
- [Enabling Concurrent Mode](#concurrent-mode)
3030
- [`createRoot`](#createroot)
31-
- [`createBlockingRoot`](#createblockingroot)
3231
- [Suspense](#suspense)
3332
- [`Suspense`](#suspensecomponent)
3433
- [`SuspenseList`](#suspenselist)
@@ -47,18 +46,6 @@ Replaces `ReactDOM.render(<App />, rootNode)` and enables Concurrent Mode.
4746

4847
For more information on Concurrent Mode, check out the [Concurrent Mode documentation.](/docs/concurrent-mode-intro.html)
4948

50-
### `createBlockingRoot` {#createblockingroot}
51-
52-
```js
53-
ReactDOM.createBlockingRoot(rootNode).render(<App />)
54-
```
55-
56-
Replaces `ReactDOM.render(<App />, rootNode)` and enables [Blocking Mode](/docs/concurrent-mode-adoption.html#migration-step-blocking-mode).
57-
58-
Opting into Concurrent Mode introduces semantic changes to how React works. This means that you can't use Concurrent Mode in just a few components. Because of this, some apps may not be able to migrate directly to Concurrent Mode.
59-
60-
Blocking Mode only contains a small subset of Concurrent Mode features and is intended as an intermediary migration step for apps that are unable to migrate directly.
61-
6249
## Suspense API {#suspense}
6350

6451
### `Suspense` {#suspensecomponent}

content/docs/hooks-reference.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@ If your update function returns the exact same value as the current state, the s
7676
> Unlike the `setState` method found in class components, `useState` does not automatically merge update objects. You can replicate this behavior by combining the function updater form with object spread syntax:
7777
>
7878
> ```js
79+
> const [state, setState] = useState({});
7980
> setState(prevState => {
8081
> // Object.assign would also work
8182
> return {...prevState, ...updatedValues};

0 commit comments

Comments
 (0)