From 4fae9e8905873922e9374465de5aee19f2455f39 Mon Sep 17 00:00:00 2001 From: numb86 <16703337+numb86@users.noreply.github.com> Date: Tue, 4 Feb 2020 07:53:12 +0900 Subject: [PATCH 01/15] Fix internal link (#2668) --- content/docs/concurrent-mode-adoption.md | 2 +- content/docs/how-to-contribute.md | 4 ++-- content/docs/reference-profiler.md | 4 ++-- content/docs/refs-and-the-dom.md | 2 +- content/docs/testing-environments.md | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/content/docs/concurrent-mode-adoption.md b/content/docs/concurrent-mode-adoption.md index 45d3b0ea3..8d7ed8cbc 100644 --- a/content/docs/concurrent-mode-adoption.md +++ b/content/docs/concurrent-mode-adoption.md @@ -80,7 +80,7 @@ ReactDOM.createRoot( > >Concurrent Mode APIs such as `createRoot` only exist in the experimental builds of React. -In Concurrent Mode, the lifecycle methods [previously marked](https://reactjs.org/blog/2018/03/27/update-on-async-rendering.html) as "unsafe" actually *are* unsafe, and lead to bugs even more than in today's React. We don't recommend trying Concurrent Mode until your app is [Strict Mode](https://reactjs.org/docs/strict-mode.html)-compatible. +In Concurrent Mode, the lifecycle methods [previously marked](/blog/2018/03/27/update-on-async-rendering.html) as "unsafe" actually *are* unsafe, and lead to bugs even more than in today's React. We don't recommend trying Concurrent Mode until your app is [Strict Mode](/docs/strict-mode.html)-compatible. ## What to Expect {#what-to-expect} diff --git a/content/docs/how-to-contribute.md b/content/docs/how-to-contribute.md index ca872712d..2eb71ec21 100644 --- a/content/docs/how-to-contribute.md +++ b/content/docs/how-to-contribute.md @@ -21,7 +21,7 @@ All work on React happens directly on [GitHub](https://github.com/facebook/react ### Semantic Versioning {#semantic-versioning} -React follows [semantic versioning](https://semver.org/). We release patch versions for critical bugfixes, minor versions for new features or non-essential changes, and major versions for any breaking changes. When we make breaking changes, we also introduce deprecation warnings in a minor version so that our users learn about the upcoming changes and migrate their code in advance. Learn more about our commitment to stability and incremental migration in [our versioning policy](https://reactjs.org/docs/faq-versioning.html). +React follows [semantic versioning](https://semver.org/). We release patch versions for critical bugfixes, minor versions for new features or non-essential changes, and major versions for any breaking changes. When we make breaking changes, we also introduce deprecation warnings in a minor version so that our users learn about the upcoming changes and migrate their code in advance. Learn more about our commitment to stability and incremental migration in [our versioning policy](/docs/faq-versioning.html). Every significant change is documented in the [changelog file](https://github.com/facebook/react/blob/master/CHANGELOG.md). @@ -56,7 +56,7 @@ Facebook has a [bounty program](https://www.facebook.com/whitehat/) for the safe ### How to Get in Touch {#how-to-get-in-touch} * IRC: [#reactjs on freenode](https://webchat.freenode.net/?channels=reactjs) -* [Discussion forums](https://reactjs.org/community/support.html#popular-discussion-forums) +* [Discussion forums](/community/support.html#popular-discussion-forums) There is also [an active community of React users on the Discord chat platform](https://www.reactiflux.com/) in case you need help with React. diff --git a/content/docs/reference-profiler.md b/content/docs/reference-profiler.md index 7c03dc63b..bd80403c8 100644 --- a/content/docs/reference-profiler.md +++ b/content/docs/reference-profiler.md @@ -7,11 +7,11 @@ permalink: docs/profiler.html --- The `Profiler` measures how often a React application renders and what the "cost" of rendering is. -Its purpose is to help identify parts of an application that are slow and may benefit from [optimizations such as memoization](https://reactjs.org/docs/hooks-faq.html#how-to-memoize-calculations). +Its purpose is to help identify parts of an application that are slow and may benefit from [optimizations such as memoization](/docs/hooks-faq.html#how-to-memoize-calculations). > Note: > -> Profiling adds some additional overhead, so **it is disabled in [the production build](https://reactjs.org/docs/optimizing-performance.html#use-the-production-build)**. +> Profiling adds some additional overhead, so **it is disabled in [the production build](/docs/optimizing-performance.html#use-the-production-build)**. > > To opt into production profiling, React provides a special production build with profiling enabled. > Read more about how to use this build at [fb.me/react-profiling](https://fb.me/react-profiling) diff --git a/content/docs/refs-and-the-dom.md b/content/docs/refs-and-the-dom.md index 8ba52d2fa..e18ab9683 100644 --- a/content/docs/refs-and-the-dom.md +++ b/content/docs/refs-and-the-dom.md @@ -161,7 +161,7 @@ class Parent extends React.Component { } ``` -If you want to allow people to take a `ref` to your function component, you can use [`forwardRef`](https://reactjs.org/docs/forwarding-refs.html) (possibly in conjunction with [`useImperativeHandle`](/docs/hooks-reference.html#useimperativehandle)), or you can convert the component to a class. +If you want to allow people to take a `ref` to your function component, you can use [`forwardRef`](/docs/forwarding-refs.html) (possibly in conjunction with [`useImperativeHandle`](/docs/hooks-reference.html#useimperativehandle)), or you can convert the component to a class. You can, however, **use the `ref` attribute inside a function component** as long as you refer to a DOM element or a class component: diff --git a/content/docs/testing-environments.md b/content/docs/testing-environments.md index d77e76f44..c03714d01 100644 --- a/content/docs/testing-environments.md +++ b/content/docs/testing-environments.md @@ -29,7 +29,7 @@ A large portion of UI tests can be written with the above setup: using Jest as a If you're writing a library that tests mostly browser-specific behavior, and requires native browser behavior like layout or real inputs, you could use a framework like [mocha.](https://mochajs.org/) -In an environment where you _can't_ simulate a DOM (e.g. testing React Native components on Node.js), you could use [event simulation helpers](https://reactjs.org/docs/test-utils.html#simulate) to simulate interactions with elements. Alternately, you could use the `fireEvent` helper from [`@testing-library/react-native`](https://testing-library.com/docs/native-testing-library). +In an environment where you _can't_ simulate a DOM (e.g. testing React Native components on Node.js), you could use [event simulation helpers](/docs/test-utils.html#simulate) to simulate interactions with elements. Alternately, you could use the `fireEvent` helper from [`@testing-library/react-native`](https://testing-library.com/docs/native-testing-library). Frameworks like [Cypress](https://www.cypress.io/), [puppeteer](https://github.com/GoogleChrome/puppeteer) and [webdriver](https://www.seleniumhq.org/projects/webdriver/) are useful for running [end-to-end tests](#end-to-end-tests-aka-e2e-tests). From 10b052d11c3062d4af861c685d11c00590b0d194 Mon Sep 17 00:00:00 2001 From: Ailuue Date: Wed, 5 Feb 2020 10:04:29 +0800 Subject: [PATCH 02/15] Add "Chain React 2020" (#2714) Adds details for the July "Chain React 2020" conference in Portland, OR. --- content/community/conferences.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/content/community/conferences.md b/content/community/conferences.md index 74fff851b..6cbc3169e 100644 --- a/content/community/conferences.md +++ b/content/community/conferences.md @@ -82,6 +82,11 @@ July 18, 2020. Medellín, Colombia. [Website](https://reactlaconf.co/) - [Twitter](https://twitter.com/reactlaconf) +### Chain React 2020 {#chain-react-2020} +July 29-30, 2020. Portland, Oregon, USA. + +[Website](https://infinite.red/ChainReactConf) - [Twitter](https://twitter.com/ChainReactConf) + ### ComponentsConf 2020 {#components20} September 1, 2020 in Melbourne, Australia From f1a13ae1c113e4b20299c1a7fd0769d15195fb11 Mon Sep 17 00:00:00 2001 From: Philip Middleton Date: Thu, 6 Feb 2020 14:58:13 -0500 Subject: [PATCH 03/15] Added the Ann Arbor Michigan Meetup to the US list. (#1723) --- content/community/meetups.md | 1 + 1 file changed, 1 insertion(+) diff --git a/content/community/meetups.md b/content/community/meetups.md index 1d2e48afe..320506649 100644 --- a/content/community/meetups.md +++ b/content/community/meetups.md @@ -148,6 +148,7 @@ Do you have a local React.js meetup? Add it here! (Please keep the list alphabet * [Kyiv](https://www.meetup.com/Kyiv-ReactJS-Meetup) ## US {#us} +* [Ann Arbor, MI - ReactJS](https://www.meetup.com/AnnArbor-jsx/) * [Atlanta, GA - ReactJS](https://www.meetup.com/React-ATL/) * [Austin, TX - ReactJS](https://www.meetup.com/ReactJS-Austin-Meetup/) * [Boston, MA - ReactJS](https://www.meetup.com/ReactJS-Boston/) From c9fe940cb0a7eb6acffa546641a43178ed849e89 Mon Sep 17 00:00:00 2001 From: Sophie Alpert Date: Sat, 8 Feb 2020 15:09:29 -0800 Subject: [PATCH 04/15] Update faq-versioning.md It's 2020 already. --- content/docs/faq-versioning.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/docs/faq-versioning.md b/content/docs/faq-versioning.md index df45e05a3..c32677eb7 100644 --- a/content/docs/faq-versioning.md +++ b/content/docs/faq-versioning.md @@ -22,7 +22,7 @@ Minor releases are the most common type of release. ### Breaking Changes {#breaking-changes} -Breaking changes are inconvenient for everyone, so we try to minimize the number of major releases – for example, React 15 was released in April 2016 and React 16 was released in September 2017; React 17 isn't expected until 2019. +Breaking changes are inconvenient for everyone, so we try to minimize the number of major releases – for example, React 15 was released in April 2016 and React 16 was released in September 2017; React 17 isn't expected until sometime in 2020. Instead, we release new features in minor versions. That means that minor releases are often more interesting and compelling than majors, despite their unassuming name. From e5edde701a268564c21c56b2324a6bed1b0de2ff Mon Sep 17 00:00:00 2001 From: Sam Cook <58375830+sjc5@users.noreply.github.com> Date: Sun, 9 Feb 2020 17:38:57 -0600 Subject: [PATCH 05/15] Corrected minor grammar issue (#2726) On line 40, the phrase following the 'comma and' should be independent (i.e., contain a subject). Alternatively, the comma preceding the 'and' should be deleted, making the dependent clause following the 'and' grammatically acceptable. --- content/tutorial/tutorial.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/tutorial/tutorial.md b/content/tutorial/tutorial.md index 579c7477a..12e943c5c 100644 --- a/content/tutorial/tutorial.md +++ b/content/tutorial/tutorial.md @@ -37,7 +37,7 @@ In this tutorial, we'll show how to build an interactive tic-tac-toe game with R You can see what we'll be building here: **[Final Result](https://codepen.io/gaearon/pen/gWWZgR?editors=0010)**. If the code doesn't make sense to you, or if you are unfamiliar with the code's syntax, don't worry! The goal of this tutorial is to help you understand React and its syntax. -We recommend that you check out the tic-tac-toe game before continuing with the tutorial. One of the features that you'll notice is that there is a numbered list to the right of the game's board. This list gives you a history of all of the moves that have occurred in the game, and is updated as the game progresses. +We recommend that you check out the tic-tac-toe game before continuing with the tutorial. One of the features that you'll notice is that there is a numbered list to the right of the game's board. This list gives you a history of all of the moves that have occurred in the game, and it is updated as the game progresses. You can close the tic-tac-toe game once you're familiar with it. We'll be starting from a simpler template in this tutorial. Our next step is to set you up so that you can start building the game. From 4367566bddd06ed9dfbd6b1c3f45f9925e60b2c3 Mon Sep 17 00:00:00 2001 From: Jakub Drozdek <30927218+jakubdrozdek@users.noreply.github.com> Date: Mon, 10 Feb 2020 00:41:06 +0100 Subject: [PATCH 06/15] Remove part about stateless components (#2694) --- content/docs/react-without-jsx.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/docs/react-without-jsx.md b/content/docs/react-without-jsx.md index 85cdba45f..95a5ca967 100644 --- a/content/docs/react-without-jsx.md +++ b/content/docs/react-without-jsx.md @@ -40,7 +40,7 @@ ReactDOM.render( If you're curious to see more examples of how JSX is converted to JavaScript, you can try out [the online Babel compiler](babel://jsx-simple-example). -The component can either be provided as a string, or as a subclass of `React.Component`, or a plain function for stateless components. +The component can either be provided as a string, as a subclass of `React.Component`, or a plain function. If you get tired of typing `React.createElement` so much, one common pattern is to assign a shorthand: From 01eeee898998958bd6f22c257d2f837e6089dd49 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rainer=20Mart=C3=ADnez=20Fraga?= Date: Mon, 10 Feb 2020 14:29:12 -0500 Subject: [PATCH 07/15] Update meetups.md --- content/community/meetups.md | 4 ---- 1 file changed, 4 deletions(-) diff --git a/content/community/meetups.md b/content/community/meetups.md index b3a2ea1eb..5d500f5ff 100644 --- a/content/community/meetups.md +++ b/content/community/meetups.md @@ -148,12 +148,8 @@ permalink: community/meetups.html ## Ucrania {#ukraine} * [Kiev](https://www.meetup.com/Kyiv-ReactJS-Meetup) -<<<<<<< HEAD ## Estados Unidos {#us} -======= -## US {#us} * [Ann Arbor, MI - ReactJS](https://www.meetup.com/AnnArbor-jsx/) ->>>>>>> 4367566bddd06ed9dfbd6b1c3f45f9925e60b2c3 * [Atlanta, GA - ReactJS](https://www.meetup.com/React-ATL/) * [Austin, TX - ReactJS](https://www.meetup.com/ReactJS-Austin-Meetup/) * [Boston, MA - ReactJS](https://www.meetup.com/ReactJS-Boston/) From 7f1014777d273f562100d3f6a8c5be5f667e2178 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rainer=20Mart=C3=ADnez=20Fraga?= Date: Mon, 10 Feb 2020 14:30:36 -0500 Subject: [PATCH 08/15] Update concurrent-mode-adoption.md --- content/docs/concurrent-mode-adoption.md | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/content/docs/concurrent-mode-adoption.md b/content/docs/concurrent-mode-adoption.md index e01cd33c4..44ee1b85d 100755 --- a/content/docs/concurrent-mode-adoption.md +++ b/content/docs/concurrent-mode-adoption.md @@ -80,11 +80,7 @@ ReactDOM.createRoot( > >Las API del Modo Concurrente como `createRoot` solo existen en los compilados experimentadles de React. -<<<<<<< HEAD -En el Modo Concurrente, los métodos de ciclo de vida [previamente marcados](https://reactjs.org/blog/2018/03/27/update-on-async-rendering.html) como "inseguros" de hecho son inseguros, y conducen aún a más errores que en React hoy en día. No recomendamos intentar el Modo Concurrente hasta que tu aplicación sea compatible con el [Modo estricto](https://reactjs.org/docs/strict-mode.html). -======= -In Concurrent Mode, the lifecycle methods [previously marked](/blog/2018/03/27/update-on-async-rendering.html) as "unsafe" actually *are* unsafe, and lead to bugs even more than in today's React. We don't recommend trying Concurrent Mode until your app is [Strict Mode](/docs/strict-mode.html)-compatible. ->>>>>>> 4367566bddd06ed9dfbd6b1c3f45f9925e60b2c3 +En el Modo Concurrente, los métodos de ciclo de vida [previamente marcados](/blog/2018/03/27/update-on-async-rendering.html) como "inseguros" de hecho son inseguros, y conducen aún a más errores que en React hoy en día. No recomendamos intentar el Modo Concurrente hasta que tu aplicación sea compatible con el [Modo estricto](/docs/strict-mode.html). ## ¿Qué esperar? {#what-to-expect} From 4c94f8484744436097ff112e20de2540bf3b8b14 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rainer=20Mart=C3=ADnez=20Fraga?= Date: Mon, 10 Feb 2020 14:31:50 -0500 Subject: [PATCH 09/15] Update faq-versioning.md --- content/docs/faq-versioning.md | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/content/docs/faq-versioning.md b/content/docs/faq-versioning.md index 5d493d847..8dfc2a7d0 100644 --- a/content/docs/faq-versioning.md +++ b/content/docs/faq-versioning.md @@ -22,11 +22,7 @@ Los lanzamientos menores son el tipo de lanzamiento más común. ### Cambios con rupturas {#breaking-changes} -<<<<<<< HEAD -Los cambios con rupturas son inconvenientes para todos, por lo que intentamos minimizar el número de lanzamientos importantes – por ejemplo, React 15 fue lanzado en Abril de 2016 y React 16 fue lanzado en Septiembre de 2017; no esperamos lanzar React 17 hasta el 2019. -======= -Breaking changes are inconvenient for everyone, so we try to minimize the number of major releases – for example, React 15 was released in April 2016 and React 16 was released in September 2017; React 17 isn't expected until sometime in 2020. ->>>>>>> 4367566bddd06ed9dfbd6b1c3f45f9925e60b2c3 +Los cambios con rupturas son inconvenientes para todos, por lo que intentamos minimizar el número de lanzamientos importantes – por ejemplo, React 15 fue lanzado en Abril de 2016 y React 16 fue lanzado en Septiembre de 2017; no esperamos lanzar React 17 hasta algún momento en el 2020. En cambio, lanzamos nuevas funcionalidades en versiones menores. Esto significa que los lanzamientos menores son a menudo más interesantes que los lanzamientos importantes, a pesar de su modesto nombre. From ccf2935ea305c8f1d3b1e514661fcda7db848f64 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rainer=20Mart=C3=ADnez=20Fraga?= Date: Mon, 10 Feb 2020 14:33:20 -0500 Subject: [PATCH 10/15] Update how-to-contribute.md --- content/docs/how-to-contribute.md | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/content/docs/how-to-contribute.md b/content/docs/how-to-contribute.md index 81f8a2fac..38742a296 100644 --- a/content/docs/how-to-contribute.md +++ b/content/docs/how-to-contribute.md @@ -21,11 +21,7 @@ Todo el trabajo en React sucede directamente en [GitHub](https://github.com/face ### Versionado semántico {#semantic-versioning} -<<<<<<< HEAD -React utiliza [versionado semántico](https://semver.org/). Lanzamos versiones con parches para arreglos de errores críticos, versiones menores para nuevas funcionalidades o cambios no esenciales, y versiones mayores para cualquier cambio disruptivo. Cuando creamos cambios disruptivos, también agregamos alertas de obsolescencia para que los usuarios aprendan sobre los cambios que vienen y migren su código con antelación. Aprende más sobre nuestro compromiso con la estabilidad y la migración incremental en [nuestra política de versionado](https://reactjs.org/docs/faq-versioning.html). -======= -React follows [semantic versioning](https://semver.org/). We release patch versions for critical bugfixes, minor versions for new features or non-essential changes, and major versions for any breaking changes. When we make breaking changes, we also introduce deprecation warnings in a minor version so that our users learn about the upcoming changes and migrate their code in advance. Learn more about our commitment to stability and incremental migration in [our versioning policy](/docs/faq-versioning.html). ->>>>>>> 4367566bddd06ed9dfbd6b1c3f45f9925e60b2c3 +React utiliza [versionado semántico](https://semver.org/). Lanzamos versiones con parches para arreglos de errores críticos, versiones menores para nuevas funcionalidades o cambios no esenciales, y versiones mayores para cualquier cambio disruptivo. Cuando creamos cambios disruptivos, también agregamos alertas de obsolescencia para que los usuarios aprendan sobre los cambios que vienen y migren su código con antelación. Aprende más sobre nuestro compromiso con la estabilidad y la migración incremental en [nuestra política de versionado](/docs/faq-versioning.html). Cada cambio significativo es documentado en el [archivo de cambios](https://github.com/facebook/react/blob/master/CHANGELOG.md). @@ -59,13 +55,8 @@ Facebook tiene un [programa de recompensas](https://www.facebook.com/whitehat/) ### Cómo entrar en contacto {#how-to-get-in-touch} -<<<<<<< HEAD * IRC: [#reactjs en freenode](https://webchat.freenode.net/?channels=reactjs) -* Foro de discusión: [discuss.reactjs.org](https://es.reactjs.org/community/support.html#popular-discussion-forums) -======= -* IRC: [#reactjs on freenode](https://webchat.freenode.net/?channels=reactjs) -* [Discussion forums](/community/support.html#popular-discussion-forums) ->>>>>>> 4367566bddd06ed9dfbd6b1c3f45f9925e60b2c3 +* Foro de discusión: [discuss.reactjs.org](/community/support.html#popular-discussion-forums) También hay [una comunidad activa de usuarios de React en la plataforma de chat Discord](https://www.reactiflux.com/) en caso de que necesites ayuda con React. From cc7de71a6d8a0fd449f5d9ba5d758fff9c53a827 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rainer=20Mart=C3=ADnez=20Fraga?= Date: Mon, 10 Feb 2020 14:34:08 -0500 Subject: [PATCH 11/15] Update react-without-jsx.md --- content/docs/react-without-jsx.md | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/content/docs/react-without-jsx.md b/content/docs/react-without-jsx.md index e86503155..c829c998d 100644 --- a/content/docs/react-without-jsx.md +++ b/content/docs/react-without-jsx.md @@ -40,11 +40,7 @@ ReactDOM.render( Si tienes curiosidad por ver más ejemplos de cómo JSX se convierte a Javascript, puedes probar el [compilador en línea de Babel](babel://jsx-simple-example). -<<<<<<< HEAD -El componente puede ser proporcionado como una cadena, como una subclase de `React.Component`, o una función simple para componentes sin estado. -======= -The component can either be provided as a string, as a subclass of `React.Component`, or a plain function. ->>>>>>> 4367566bddd06ed9dfbd6b1c3f45f9925e60b2c3 +El componente puede ser proporcionado como una cadena, como una subclase de `React.Component`, o una función simple. Si te cansas de escribir tanto `React.createElement`, un patrón común es asignarlo a una variable corta: From a21254b0f201f9f9079db88be519b7f4d64ce5bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rainer=20Mart=C3=ADnez=20Fraga?= Date: Mon, 10 Feb 2020 14:35:41 -0500 Subject: [PATCH 12/15] Update reference-profiler.md --- content/docs/reference-profiler.md | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/content/docs/reference-profiler.md b/content/docs/reference-profiler.md index 75596ee9b..74e5b4060 100644 --- a/content/docs/reference-profiler.md +++ b/content/docs/reference-profiler.md @@ -6,21 +6,12 @@ category: Reference permalink: docs/profiler.html --- -<<<<<<< HEAD El `Profiler` (perfilador o generador de perfiles) mide con qué frecuencia se renderiza una aplicación React y cuál es el "costo" del renderizado. -Su propósito es ayudar a identificar partes de una aplicación que son lentas y pueden beneficiarse de [optimizaciones como la memoización](https://reactjs.org/docs/hooks-faq.html#how-to-memoize-calculations). -======= -The `Profiler` measures how often a React application renders and what the "cost" of rendering is. -Its purpose is to help identify parts of an application that are slow and may benefit from [optimizations such as memoization](/docs/hooks-faq.html#how-to-memoize-calculations). ->>>>>>> 4367566bddd06ed9dfbd6b1c3f45f9925e60b2c3 +Su propósito es ayudar a identificar partes de una aplicación que son lentas y pueden beneficiarse de [optimizaciones como la memoización](/docs/hooks-faq.html#how-to-memoize-calculations). > Nota: > -<<<<<<< HEAD -> La creación de perfiles agrega una sobrecarga adicional, por lo que **está deshabilitada en [la compilación de producción](https://reactjs.org/docs/optimizing-performance.html#use-the-production-build)**. -======= -> Profiling adds some additional overhead, so **it is disabled in [the production build](/docs/optimizing-performance.html#use-the-production-build)**. ->>>>>>> 4367566bddd06ed9dfbd6b1c3f45f9925e60b2c3 +> La creación de perfiles agrega una sobrecarga adicional, por lo que **está deshabilitada en [la compilación de producción](/docs/optimizing-performance.html#use-the-production-build)**. > > Para acceder al análisis de rendimiento en producción, React proporciona una compilación de producción especial con la generación de perfiles habilitada. > Lea más sobre cómo usar esta compilación en [fb.me/react-profiling](https://fb.me/react-profiling) From 18336798c9dfc8481f7b94207914fae4b58c77aa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rainer=20Mart=C3=ADnez=20Fraga?= Date: Mon, 10 Feb 2020 14:36:46 -0500 Subject: [PATCH 13/15] Update refs-and-the-dom.md --- content/docs/refs-and-the-dom.md | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/content/docs/refs-and-the-dom.md b/content/docs/refs-and-the-dom.md index 120b1982c..f598fe44a 100644 --- a/content/docs/refs-and-the-dom.md +++ b/content/docs/refs-and-the-dom.md @@ -161,11 +161,7 @@ class Parent extends React.Component { } ``` -<<<<<<< HEAD -Sí deseas permitir que las personas tomen una `ref` de tu componente de función, puedes usar [`forwardRef`](https://reactjs.org/docs/forwarding-refs.html) (posiblemente en conjunto con [`useImperativeHandle`](/docs/hooks-reference.html#useimperativehandle)), o puedes convertir el componente a una clase. -======= -If you want to allow people to take a `ref` to your function component, you can use [`forwardRef`](/docs/forwarding-refs.html) (possibly in conjunction with [`useImperativeHandle`](/docs/hooks-reference.html#useimperativehandle)), or you can convert the component to a class. ->>>>>>> 4367566bddd06ed9dfbd6b1c3f45f9925e60b2c3 +Sí deseas permitir que las personas tomen una `ref` de tu componente de función, puedes usar [`forwardRef`](/docs/forwarding-refs.html) (posiblemente en conjunto con [`useImperativeHandle`](/docs/hooks-reference.html#useimperativehandle)), o puedes convertir el componente a una clase. Sin embargo, puedes **usar el atributo `ref` dentro de un componente de función** siempre y cuando hagas referencia de un elemento del DOM o de un componente de clase. From e7a773fd66b1a2f61f43c51d235cf05aec2bbe3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rainer=20Mart=C3=ADnez=20Fraga?= Date: Mon, 10 Feb 2020 14:37:42 -0500 Subject: [PATCH 14/15] Update testing-environments.md --- content/docs/testing-environments.md | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/content/docs/testing-environments.md b/content/docs/testing-environments.md index 35a19d807..6df2e9d29 100644 --- a/content/docs/testing-environments.md +++ b/content/docs/testing-environments.md @@ -29,11 +29,7 @@ Una gran parte de pruebas a la interfaz gráfica pueden ser escritas con la conf Si estas escribiendo una biblioteca que prueba principalmente un comportamiento específico del navegador y requiere comportamiento nativo del navegador como el layout o inputs reales, puedes usar un framewrok como [mocha.](https://mochajs.org/) -<<<<<<< HEAD -En un entorno donde _no puedes_ simular el DOM (por ejemplo, probando componentes de React Native en Node.js), podrías usar [simuladores de eventos](https://reactjs.org/docs/test-utils.html#simulate) para simular interacciones con elementos. De manera alternativa, también puedes usar el _helper_ `fireEvent` de [`@testing-library/react-native`](https://testing-library.com/docs/native-testing-library). -======= -In an environment where you _can't_ simulate a DOM (e.g. testing React Native components on Node.js), you could use [event simulation helpers](/docs/test-utils.html#simulate) to simulate interactions with elements. Alternately, you could use the `fireEvent` helper from [`@testing-library/react-native`](https://testing-library.com/docs/native-testing-library). ->>>>>>> 4367566bddd06ed9dfbd6b1c3f45f9925e60b2c3 +En un entorno donde _no puedes_ simular el DOM (por ejemplo, probando componentes de React Native en Node.js), podrías usar [simuladores de eventos](/docs/test-utils.html#simulate) para simular interacciones con elementos. De manera alternativa, también puedes usar el _helper_ `fireEvent` de [`@testing-library/react-native`](https://testing-library.com/docs/native-testing-library). Frameworks como [Cypress](https://www.cypress.io/), [puppeteer](https://github.com/GoogleChrome/puppeteer) y [webdriver](https://www.seleniumhq.org/projects/webdriver/) son útiles para ejecutar pruebas ["end-to-end"](#end-to-end-tests-aka-e2e-tests). From d09341a3ace469a2bb0ba3623d0434d620866150 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rainer=20Mart=C3=ADnez=20Fraga?= Date: Mon, 10 Feb 2020 14:39:55 -0500 Subject: [PATCH 15/15] Update tutorial.md --- content/tutorial/tutorial.md | 4 ---- 1 file changed, 4 deletions(-) diff --git a/content/tutorial/tutorial.md b/content/tutorial/tutorial.md index ed5066086..c11fa62df 100644 --- a/content/tutorial/tutorial.md +++ b/content/tutorial/tutorial.md @@ -37,11 +37,7 @@ En este tutorial, te mostraremos cómo construir un juego de tic-tac-toe interac Puedes ver lo que construiremos aquí: **[Resultado Final](https://codepen.io/gaearon/pen/gWWZgR?editors=0010)**. Si el código no te hace sentido, o si no estás familiarizado con la sintaxis de código, ¡no te preocupes! El objetivo de este tutorial es ayudarte a entender React y su sintaxis. -<<<<<<< HEAD Recomendamos que revises el juego de tic-tac-toe antes de continuar con el tutorial. Una de las características que notarás es que hay una lista enumerada a la derecha del tablero del jugador. Esta lista da una historia de todos los movimientos que han ocurrido en el juego, y se va actualizando conforme el juego progresa. -======= -We recommend that you check out the tic-tac-toe game before continuing with the tutorial. One of the features that you'll notice is that there is a numbered list to the right of the game's board. This list gives you a history of all of the moves that have occurred in the game, and it is updated as the game progresses. ->>>>>>> 4367566bddd06ed9dfbd6b1c3f45f9925e60b2c3 Puedes cerrar el juego de tic-tac-toe una vez que te familiarizaste con él. Empezaremos desde una plantilla más simple en este tutorial. Nuestro siguiente paso es configurarlo de tal forma que puedas empezar a construir el juego.