Skip to content

Commit 97ec4b8

Browse files
authored
Merge pull request #27 from reactjs/sync-a8790ca8
Sync with react.dev @ a8790ca
2 parents 0a47a02 + 48484d8 commit 97ec4b8

17 files changed

+687
-177
lines changed
Loading
Loading
Loading
Loading

src/components/Layout/getRouteMeta.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,13 +58,13 @@ export interface RouteMeta {
5858
order?: number;
5959
}
6060

61-
type TravesalContext = RouteMeta & {
61+
type TraversalContext = RouteMeta & {
6262
currentIndex: number;
6363
};
6464

6565
export function getRouteMeta(cleanedPath: string, routeTree: RouteItem) {
6666
const breadcrumbs = getBreadcrumbs(cleanedPath, routeTree);
67-
const ctx: TravesalContext = {
67+
const ctx: TraversalContext = {
6868
currentIndex: 0,
6969
};
7070
buildRouteMeta(cleanedPath, routeTree, ctx);
@@ -79,7 +79,7 @@ export function getRouteMeta(cleanedPath: string, routeTree: RouteItem) {
7979
function buildRouteMeta(
8080
searchPath: string,
8181
currentRoute: RouteItem,
82-
ctx: TravesalContext
82+
ctx: TraversalContext
8383
) {
8484
ctx.currentIndex++;
8585

src/content/blog/2023/03/22/react-labs-what-we-have-been-working-on-march-2023.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ Making plain JavaScript in React components reactive requires a compiler with a
7474

7575
## Offscreen Rendering {/*offscreen-rendering*/}
7676

77-
Offscreen rendering is an upcoming capability in React for rendering screens in the background without additional performance overhead. You can think of it as a version of the [`content-visiblity` CSS property](https://developer.mozilla.org/en-US/docs/Web/CSS/content-visibility) that works not only for DOM elements but React components, too. During our research, we've discovered a variety of use cases:
77+
Offscreen rendering is an upcoming capability in React for rendering screens in the background without additional performance overhead. You can think of it as a version of the [`content-visibility` CSS property](https://developer.mozilla.org/en-US/docs/Web/CSS/content-visibility) that works not only for DOM elements but React components, too. During our research, we've discovered a variety of use cases:
7878

7979
- A router can prerender screens in the background so that when a user navigates to them, they're instantly available.
8080
- A tab switching component can preserve the state of hidden tabs, so the user can switch between them without losing their progress.

src/content/learn/passing-data-deeply-with-context.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -985,7 +985,7 @@ export const places = [{
985985
}, {
986986
id: 5,
987987
name: 'Chefchaouen, Marocco',
988-
description: 'There are a few theories on why the houses are painted blue, including that the color repells mosquitos or that it symbolizes sky and heaven.',
988+
description: 'There are a few theories on why the houses are painted blue, including that the color repels mosquitos or that it symbolizes sky and heaven.',
989989
imageId: 'rTqKo46'
990990
}, {
991991
id: 6,
@@ -1124,7 +1124,7 @@ export const places = [{
11241124
}, {
11251125
id: 5,
11261126
name: 'Chefchaouen, Marocco',
1127-
description: 'There are a few theories on why the houses are painted blue, including that the color repells mosquitos or that it symbolizes sky and heaven.',
1127+
description: 'There are a few theories on why the houses are painted blue, including that the color repels mosquitos or that it symbolizes sky and heaven.',
11281128
imageId: 'rTqKo46'
11291129
}, {
11301130
id: 6,

src/content/reference/react-dom/components/form.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ export async function deliverMessage(message) {
273273

274274
</Sandpack>
275275

276-
[//]: # 'Uncomment the next line, and delete this line after the `useOptimisitc` reference documentatino page is published'
276+
[//]: # 'Uncomment the next line, and delete this line after the `useOptimistic` reference documentatino page is published'
277277
[//]: # 'To learn more about the `useOptimistic` Hook see the [reference documentation](/reference/react/hooks/useOptimistic).'
278278

279279
### Handling form submission errors {/*handling-form-submission-errors*/}

src/content/reference/react/Component.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -632,7 +632,7 @@ class Form extends Component {
632632
return (
633633
<>
634634
<input value={this.state.name} onChange={this.handleNameChange} />
635-
<p>Hello, {this.state.name}.
635+
<p>Hello, {this.state.name}.</p>
636636
</>
637637
);
638638
}

src/content/reference/react/cache.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -309,7 +309,7 @@ async function DemoProfile() {
309309
310310
React only provides cache access to the memoized function in a component. When calling <CodeStep step={1}>`getUser`</CodeStep> outside of a component, it will still evaluate the function but not read or update the cache.
311311
312-
This is because cache access is provided through a [context](/learn/passing-data-deeply-with-context) which is only accessibile from a component.
312+
This is because cache access is provided through a [context](/learn/passing-data-deeply-with-context) which is only accessible from a component.
313313
314314
</Pitfall>
315315

0 commit comments

Comments
 (0)