Skip to content

Commit

Permalink
Merge pull request #917 from reactjs/sync-93177e6c
Browse files Browse the repository at this point in the history
Sync with react.dev @ 93177e6
  • Loading branch information
carburo committed Apr 8, 2024
2 parents 79242fe + 6b7f208 commit ee8bbc1
Show file tree
Hide file tree
Showing 25 changed files with 212 additions and 123 deletions.
1 change: 1 addition & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ Ignora esta regla si estás describiendo específicamente una propuesta experime
- Utiliza punto y coma.
- No dejes espacio entre los nombres de las funciones y los paréntesis (`method() {}` no `method () {}`).
- En caso de duda, utiliza el estilo por defecto preferido por [Prettier](https://prettier.io/playground/).
- Siempre utiliza mayúsculas para conceptos de React como Hooks, Efectos y Transiciones.

### Resaltar

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@
"webpack-bundle-analyzer": "^4.5.0"
},
"engines": {
"node": "^16.8.0 || ^18.0.0 || ^19.0.0 || ^20.0.0"
"node": "^16.8.0 || ^18.0.0 || ^19.0.0 || ^20.0.0 || ^21.0.0"
},
"nextBundleAnalysis": {
"budget": null,
Expand Down
Binary file added public/images/team/jack-pope.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 3 additions & 3 deletions src/components/MDX/TeamMember.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ export function TeamMember({
<ExternalLink
aria-label="React on Twitter"
href={`https://twitter.com/${twitter}`}
className="hover:text-primary dark:text-primary-dark flex flex-row items-center">
className="hover:text-primary hover:underline dark:text-primary-dark flex flex-row items-center">
<IconTwitter className="pe-1" />
{twitter}
</ExternalLink>
Expand All @@ -90,7 +90,7 @@ export function TeamMember({
<ExternalLink
aria-label="GitHub Profile"
href={`https://github.com/${github}`}
className="hover:text-primary dark:text-primary-dark flex flex-row items-center">
className="hover:text-primary hover:underline dark:text-primary-dark flex flex-row items-center">
<IconGitHub className="pe-1" /> {github}
</ExternalLink>
</div>
Expand All @@ -99,7 +99,7 @@ export function TeamMember({
<ExternalLink
aria-label="Personal Site"
href={`https://${personal}`}
className="hover:text-primary dark:text-primary-dark flex flex-row items-center">
className="hover:text-primary hover:underline dark:text-primary-dark flex flex-row items-center">
<IconLink className="pe-1" /> {personal}
</ExternalLink>
)}
Expand Down
1 change: 1 addition & 0 deletions src/content/community/acknowledgements.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ Nos gustaría reconocer a algunas personas que han hecho contribuciones signific
* [Andreas Svensson](https://github.com/syranide)
* [Alex Krolick](https://github.com/alexkrolick)
* [Alexey Pyltsyn](https://github.com/lex111)
* [Andrey Lunyov](https://github.com/alunyov)
* [Brandon Dail](https://github.com/aweary)
* [Brian Vaughn](https://github.com/bvaughn)
* [Caleb Meredith](https://github.com/calebmer)
Expand Down
10 changes: 5 additions & 5 deletions src/content/community/team.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,6 @@ Engineer at Meta
Andrew comenzó con el desarrollo web creando sitios con WordPress, y y finalmente se engañó a sí mismo para hacer JavaScript. Su pasatiempo favorito es el karaoke. Andrew es un villano o una princesa de Disney, según el día.
</TeamMember>

<TeamMember name="Andrey Lunyov" permalink="andrey-lunyov" photo="/images/team/andrey-lunyov.jpg" github="alunyov" twitter="alunyov" threads="alunyov" title="Ingeniero en Meta">
Andrey comenzó su carrera como diseñador y luego pasó gradualmente al desarrollo web. Después de unirse al equipo de React Data en Meta, trabajó para agregar un compilador de JavaScript incremental a Relay y, más tarde, trabajó para eliminar el mismo compilador de Relay. Fuera del trabajo, a Andrey le gusta tocar música y practicar varios deportes.
</TeamMember>

<TeamMember name="Dan Abramov" permalink="dan-abramov" photo="/images/team/gaearon.jpg" github="gaearon" twitter="dan_abramov2" title="Ingeniero independiente">
Dan comenzó a programar después de que accidentalmente descubrió Visual Basic dentro de Microsoft PowerPoint. Ha encontrado su verdadera vocación al convertir los tweets de [Sebastian](#sebastian-markbåge) en extensas publicaciones de blog. Dan gana ocasionalmente en Fortnite escondiéndose en un arbusto hasta que termina el juego.
</TeamMember>
Expand All @@ -30,6 +26,10 @@ Engineer at Meta
Eli se metió en la programación después de que lo suspendieran de la escuela secundaria por piratear. Lleva trabajando en React y React Native desde 2017. Le gusta comer cosas ricas, especialmente helado y tarta de manzana. Puedes encontrar a Eli probando actividades extravagantes como parkour, paracaidismo en interiores y acrobacia en tela.
</TeamMember>

<TeamMember name="Jack Pope" permalink="jack-pope" photo="/images/team/jack-pope.jpg" github="jackpope" personal="jackpope.me" title="Ingeniero en Meta">
Poco después de aprender AutoHotkey, Jack empezó a escribir scripts para automatizar todo lo que se le pasara por la mente. Cuando alcanzó limitaciones allí, se sumergió de lleno en el desarrollo de aplicaciones web y no ha mirado hacia atrás. Más recientemente, Jack trabajó en la plataforma web de Instagram antes de pasar a React. Su lenguaje de programación favorito es JSX.
</TeamMember>

<TeamMember name="Jason Bonta" permalink="jason-bonta" photo="/images/team/jasonbonta.jpg" threads="someextent" title="Gerente de ingeniería en Meta">
A Jason le gusta recibir grandes cantidades de paquetes de Amazon en la oficina para poder construir fuertes. A pesar de que a veces se aísla literalmente de su equipo y no entiende cómo funcionan los bucles de for-of, le apreciamos por las cualidades únicas que aporta a su trabajo.
</TeamMember>
Expand Down Expand Up @@ -74,7 +74,7 @@ Engineer at Meta
Sebastian se especializó en psicología. Suele ser callado. Incluso, cuando dice algo, a menudo no tiene sentido para el resto de nosotros hasta unos meses después. La forma correcta de pronunciar su apellido es "mark-boa-geh", pero se ha decantado por "mark-beige" por pragmatismo, y así es como se acerca a React.
</TeamMember>

<TeamMember name="Sebastian Silbermann" permalink="sebastian-silbermann" photo="/images/team/sebsilbermann.jpg" github="eps1lon" twitter="sebsilbermann" threads="sebsilbermann" title="Ingeniero Independiente">
<TeamMember name="Sebastian Silbermann" permalink="sebastian-silbermann" photo="/images/team/sebsilbermann.jpg" github="eps1lon" twitter="sebsilbermann" threads="sebsilbermann" title="Ingeniero en Vercel">
Sebastian aprendió a programar para hacer más divertidos los juegos de navegador a los que jugaba en clase. Con el tiempo, esto le llevó a contribuir a la mayor cantidad de código abierto posible. Fuera de la programación, está ocupado asegurándose de que la gente no lo confunda con los otros Sebastian y Zilberman de la comunidad React.
</TeamMember>

Expand Down
2 changes: 1 addition & 1 deletion src/content/learn/manipulating-the-dom-with-refs.md
Original file line number Diff line number Diff line change
Expand Up @@ -494,7 +494,7 @@ En general, [no quieres](/learn/referencing-values-with-refs#best-practices-for-

React establece `ref.current` durante la confirmación. Antes de actualizar el DOM, React establece los valores afectados de `ref.current` a `null`. Después de actualizar el DOM, React inmediatamente los establece en los nodos DOM correspondientes.

**Generalmente, vas a acceder a las refs desde los controladores de eventos.** Si quieres hacer algo con una ref, pero no hay un evento en particular para hacerlo, es posible que necesites un Efecto. Discutiremos los efectos en las próximas páginas.
**Generalmente, vas a acceder a las refs desde los controladores de eventos.** Si quieres hacer algo con una ref, pero no hay un evento en particular para hacerlo, es posible que necesites un Efecto. Discutiremos los Efectos en las próximas páginas.

<DeepDive>

Expand Down
2 changes: 1 addition & 1 deletion src/content/reference/react-dom/hydrate.md
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ Esto solo funciona a un nivel de profundidad, y pretende ser una escotilla de es
### Manejar contenido diferente entre el cliente y el servidor {/*handling-different-client-and-server-content*/}
Si intencionalmente necesitas renderizar algo distinto en el servidor y el cliente, puedes hacer un renderizado en dos pasos. Los componentes que renderizan algo diferente en el cliente pueden leer una [variable de estado](/reference/react/useState) como `isClient`, que puedes establecer en `true` en un [efecto](/reference/react/useEffect):
Si intencionalmente necesitas renderizar algo distinto en el servidor y el cliente, puedes hacer un renderizado en dos pasos. Los componentes que renderizan algo diferente en el cliente pueden leer una [variable de estado](/reference/react/useState) como `isClient`, que puedes establecer en `true` en un [Efecto](/reference/react/useEffect):
<Sandpack>
Expand Down
2 changes: 1 addition & 1 deletion src/content/reference/react-dom/preconnect.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ The `preconnect` function provides the browser with a hint that it should open a
#### Caveats {/*caveats*/}

* Multiple calls to `preconnect` with the same server have the same effect as a single call.
* In the browser, you can call `preconnect` in any situation: while rendering a component, in an effect, in an event handler, and so on.
* In the browser, you can call `preconnect` in any situation: while rendering a component, in an Effect, in an event handler, and so on.
* In server-side rendering or when rendering Server Components, `preconnect` only has an effect if you call it while rendering a component or in an async context originating from rendering a component. Any other calls will be ignored.
* If you know the specific resources you'll need, you can call [other functions](/reference/react-dom/#resource-preloading-apis) instead that will start loading the resources right away.
* There is no benefit to preconnecting to the same server the webpage itself is hosted from because it's already been connected to by the time the hint would be given.
Expand Down
2 changes: 1 addition & 1 deletion src/content/reference/react-dom/prefetchDNS.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ The prefetchDNS function provides the browser with a hint that it should look up
#### Caveats {/*caveats*/}

* Multiple calls to `prefetchDNS` with the same server have the same effect as a single call.
* In the browser, you can call `prefetchDNS` in any situation: while rendering a component, in an effect, in an event handler, and so on.
* In the browser, you can call `prefetchDNS` in any situation: while rendering a component, in an Effect, in an event handler, and so on.
* In server-side rendering or when rendering Server Components, `prefetchDNS` only has an effect if you call it while rendering a component or in an async context originating from rendering a component. Any other calls will be ignored.
* If you know the specific resources you'll need, you can call [other functions](/reference/react-dom/#resource-preloading-apis) instead that will start loading the resources right away.
* There is no benefit to prefetching the same server the webpage itself is hosted from because it's already been looked up by the time the hint would be given.
Expand Down
2 changes: 1 addition & 1 deletion src/content/reference/react-dom/preinit.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ The `preinit` function provides the browser with a hint that it should start dow
#### Caveats {/*caveats*/}

* Multiple calls to `preinit` with the same `href` have the same effect as a single call.
* In the browser, you can call `preinit` in any situation: while rendering a component, in an effect, in an event handler, and so on.
* In the browser, you can call `preinit` in any situation: while rendering a component, in an Effect, in an event handler, and so on.
* In server-side rendering or when rendering Server Components, `preinit` only has an effect if you call it while rendering a component or in an async context originating from rendering a component. Any other calls will be ignored.

---
Expand Down
2 changes: 1 addition & 1 deletion src/content/reference/react-dom/preinitModule.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ The `preinitModule` function provides the browser with a hint that it should sta
#### Caveats {/*caveats*/}

* Multiple calls to `preinitModule` with the same `href` have the same effect as a single call.
* In the browser, you can call `preinitModule` in any situation: while rendering a component, in an effect, in an event handler, and so on.
* In the browser, you can call `preinitModule` in any situation: while rendering a component, in an Effect, in an event handler, and so on.
* In server-side rendering or when rendering Server Components, `preinitModule` only has an effect if you call it while rendering a component or in an async context originating from rendering a component. Any other calls will be ignored.

---
Expand Down
2 changes: 1 addition & 1 deletion src/content/reference/react-dom/preload.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ The `preload` function provides the browser with a hint that it should start dow
* Multiple equivalent calls to `preload` have the same effect as a single call. Calls to `preload` are considered equivalent according to the following rules:
* Two calls are equivalent if they have the same `href`, except:
* If `as` is set to `image`, two calls are equivalent if they have the same `href`, `imageSrcSet`, and `imageSizes`.
* In the browser, you can call `preload` in any situation: while rendering a component, in an effect, in an event handler, and so on.
* In the browser, you can call `preload` in any situation: while rendering a component, in an Effect, in an event handler, and so on.
* In server-side rendering or when rendering Server Components, `preload` only has an effect if you call it while rendering a component or in an async context originating from rendering a component. Any other calls will be ignored.

---
Expand Down
2 changes: 1 addition & 1 deletion src/content/reference/react-dom/preloadModule.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ The `preloadModule` function provides the browser with a hint that it should sta
#### Caveats {/*caveats*/}

* Multiple calls to `preloadModule` with the same `href` have the same effect as a single call.
* In the browser, you can call `preloadModule` in any situation: while rendering a component, in an effect, in an event handler, and so on.
* In the browser, you can call `preloadModule` in any situation: while rendering a component, in an Effect, in an event handler, and so on.
* In server-side rendering or when rendering Server Components, `preloadModule` only has an effect if you call it while rendering a component or in an async context originating from rendering a component. Any other calls will be ignored.

---
Expand Down
2 changes: 1 addition & 1 deletion src/content/reference/react/Profiler.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ function onRender(id, phase, actualDuration, baseDuration, startTime, commitTime
#### Parámetros {/*onrender-parameters*/}

* `id`: La prop `id` del árbol `<Profiler>` que acaba de ser entregado. Esto te permite identificar qué parte del árbol se entregó si estás usando varios perfiles.
* `phase`: `"mount"`, `"update"` o `"nested-update"`. Esto te indica si el árbol acaba de ser montado por primera vez o se ha vuelto a renderizar debido a un cambio en las props, el estado o los hooks.
* `phase`: `"mount"`, `"update"` o `"nested-update"`. Esto te indica si el árbol acaba de ser montado por primera vez o se ha vuelto a renderizar debido a un cambio en las props, el estado o los Hooks.
* `actualDuration`: El número de milisegundos que se tardó en renderizar el árbol `<Profiler>` Esto indica qué tan bien el subárbol hace uso de la memoización (por ejemplo, [`memo`](/reference/react/memo) y [`useMemo`](/reference/react/useMemo)). Idealmente, este valor debería disminuir significativamente después del montaje inicial, ya que muchos de los descendientes solo necesitarán volver a renderizarse si cambian sus propiedades específicas.
* `baseDuration`: El número de milisegundos que estima cuánto tiempo tardaría en volver a renderizar todo el subárbol `<Profiler>` sin ninguna optimización. Se calcula sumando las duraciones de renderizado más recientes de cada componente en el árbol. Este valor estima el costo del renderizado para el peor de caso (por ejemplo, el montaje inicial o un árbol sin memoización). Compara `actualDuration` con este valor para ver si la memorización está funcionando.
* `startTime`: Una marca de tiempo numérica para cuando React comenzó a renderizar la actualización actual.
Expand Down

0 comments on commit ee8bbc1

Please sign in to comment.