Skip to content

Sync with reactjs.org @ 95e15d06 #150

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 25 commits into from
Sep 14, 2021
Merged
Show file tree
Hide file tree
Changes from 46 commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
a4d4893
Add React Brussels 2021 - remote event (#3759)
AymenBenAmor Jul 6, 2021
620d360
Updated master -> main references (#3769)
Jul 6, 2021
17eae39
Fix "master" to "main" renaming mistakes (#3770)
Jul 7, 2021
71d794d
Bump urijs from 1.19.2 to 1.19.7 (#3802)
dependabot[bot] Jul 20, 2021
2c01987
mindshift -> mind shift (#3811)
ShouryaSrivastava01 Jul 26, 2021
ca08866
"the browsers" -> "browsers" (#3816)
Haroenv Jul 29, 2021
9c2b800
Update typechecking-with-proptypes.md Babel plugin-transform-class-pr…
leotm Aug 3, 2021
669890b
Use console.log in tutorial instead of alert (#3831)
bev-a-tron Aug 4, 2021
5bebe99
Explain how `ref` and `key` are treated with cloneElement (#1394)
stevemao Aug 9, 2021
401904d
Bump path-parse from 1.0.6 to 1.0.7 (#3847)
dependabot[bot] Aug 13, 2021
95e15d0
Bump url-parse from 1.4.7 to 1.5.3 (#3849)
dependabot[bot] Aug 13, 2021
90d7a10
merging all conflicts
Aug 15, 2021
24882f1
Update add-react-to-a-website.md
Ryan-LT Sep 14, 2021
71f004f
Update getting-started.md
Ryan-LT Sep 14, 2021
a25ffa9
Update handling-events.md
Ryan-LT Sep 14, 2021
dadcdce
Update lifting-state-up.md
Ryan-LT Sep 14, 2021
332f347
Update forms.md
Ryan-LT Sep 14, 2021
976e9fd
Update hello-world.md
Ryan-LT Sep 14, 2021
ac5f3ef
Update reference-react.md
Ryan-LT Sep 14, 2021
cea7843
Update hooks-intro.md
Ryan-LT Sep 14, 2021
f83326b
Update lists-and-keys.md
Ryan-LT Sep 14, 2021
e0b036a
Update thinking-in-react.md
Ryan-LT Sep 14, 2021
158765f
Update tutorial.md
Ryan-LT Sep 14, 2021
0feb66f
Update yarn.lock
Ryan-LT Sep 14, 2021
04dbf29
Merge branch 'main' into sync-95e15d06
Ryan-LT Sep 14, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Thank you for the PR! Contributors like you keep React awesome!

Please see the Contribution Guide for guidelines:

https://github.com/reactjs/reactjs.org/blob/master/CONTRIBUTING.md
https://github.com/reactjs/reactjs.org/blob/main/CONTRIBUTING.md

If your PR references an existing issue, please add the issue number below

Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@ This repo contains the source code and documentation powering [reactjs.org](http

### Guidelines

The documentation is divided into several sections with a different tone and purpose. If you plan to write more than a few sentences, you might find it helpful to get familiar with the [contributing guidelines](https://github.com/reactjs/reactjs.org/blob/master/CONTRIBUTING.md#guidelines-for-text) for the appropriate sections.
The documentation is divided into several sections with a different tone and purpose. If you plan to write more than a few sentences, you might find it helpful to get familiar with the [contributing guidelines](https://github.com/reactjs/reactjs.org/blob/main/CONTRIBUTING.md#guidelines-for-text) for the appropriate sections.

### Create a branch

1. `git checkout master` from any folder in your local `reactjs.org` repository
1. `git pull origin master` to ensure you have the latest main code
1. `git checkout main` from any folder in your local `reactjs.org` repository
1. `git pull origin main` to ensure you have the latest main code
1. `git checkout -b the-name-of-my-branch` (replacing `the-name-of-my-branch` with a suitable name) to create a branch

### Make the change
Expand Down
9 changes: 9 additions & 0 deletions content/authors.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Map of short name to more information. `name` will be used but if you don't
# want to use your real name, just use whatever. If url is included, your name
# will be a link to the provided url.
abernathyca:
name: Christine Abernathy
url: https://twitter.com/abernathyca
acdlite:
name: Andrew Clark
url: https://twitter.com/acdlite
Expand Down Expand Up @@ -70,12 +73,18 @@ petehunt:
rachelnabors:
name: Rachel Nabors
url: https://twitter.com/rachelnabors
rickhanlonii:
name: Rick Hanlon
url: https://twitter.com/rickhanlonii
schrockn:
name: Nick Schrock
url: https://twitter.com/schrockn
sebmarkbage:
name: Sebastian Markbåge
url: https://twitter.com/sebmarkbage
sethwebster:
name: Seth Webster
url: https://twitter.com/sethwebster
sophiebits:
name: Sophie Alpert
url: https://sophiebits.com/
Expand Down
2 changes: 1 addition & 1 deletion content/blog/2013-10-16-react-v0.5.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ author: [zpao]

This release is the result of several months of hard work from members of the team and the community. While there are no groundbreaking changes in core, we've worked hard to improve performance and memory usage. We've also worked hard to make sure we are being consistent in our usage of DOM properties.

The biggest change you'll notice as a developer is that we no longer support `class` in JSX as a way to provide CSS classes. Since this prop was being converted to `className` at the transform step, it caused some confusion when trying to access it in composite components. As a result we decided to make our DOM properties mirror their counterparts in the JS DOM API. There are [a few exceptions](https://github.com/facebook/react/blob/master/src/dom/DefaultDOMPropertyConfig.js#L156) where we deviate slightly in an attempt to be consistent internally.
The biggest change you'll notice as a developer is that we no longer support `class` in JSX as a way to provide CSS classes. Since this prop was being converted to `className` at the transform step, it caused some confusion when trying to access it in composite components. As a result we decided to make our DOM properties mirror their counterparts in the JS DOM API. There are [a few exceptions](https://github.com/facebook/react/blob/main/src/dom/DefaultDOMPropertyConfig.js#L156) where we deviate slightly in an attempt to be consistent internally.

The other major change in v0.5 is that we've added an additional build - `react-with-addons` - which adds support for some extras that we've been working on including animations and two-way binding. [Read more about these addons in the docs](/docs/addons.html).

Expand Down
2 changes: 1 addition & 1 deletion content/blog/2014-02-16-react-v0.9-rc1.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ React.DOM.div(null,

We believe this new behavior is more helpful and eliminates cases where unwanted whitespace was previously added.

In cases where you want to preserve the space adjacent to a newline, you can write a JS string like `{"Monkeys: "}` in your JSX source. We've included a script to do an automated codemod of your JSX source tree that preserves the old whitespace behavior by adding and removing spaces appropriately. You can [install jsx\_whitespace\_transformer from npm](https://github.com/facebook/react/blob/master/npm-jsx_whitespace_transformer/README.md) and run it over your source tree to modify files in place. The transformed JSX files will preserve your code's existing whitespace behavior.
In cases where you want to preserve the space adjacent to a newline, you can write a JS string like `{"Monkeys: "}` in your JSX source. We've included a script to do an automated codemod of your JSX source tree that preserves the old whitespace behavior by adding and removing spaces appropriately. You can [install jsx\_whitespace\_transformer from npm](https://github.com/facebook/react/blob/main/npm-jsx_whitespace_transformer/README.md) and run it over your source tree to modify files in place. The transformed JSX files will preserve your code's existing whitespace behavior.

## Changelog {#changelog}

Expand Down
2 changes: 1 addition & 1 deletion content/blog/2014-02-20-react-v0.9.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ React.DOM.div(null,

We believe this new behavior is more helpful and eliminates cases where unwanted whitespace was previously added.

In cases where you want to preserve the space adjacent to a newline, you can write `{'Monkeys: '}` or `Monkeys:{' '}` in your JSX source. We've included a script to do an automated codemod of your JSX source tree that preserves the old whitespace behavior by adding and removing spaces appropriately. You can [install jsx\_whitespace\_transformer from npm](https://github.com/facebook/react/blob/master/npm-jsx_whitespace_transformer/README.md) and run it over your source tree to modify files in place. The transformed JSX files will preserve your code's existing whitespace behavior.
In cases where you want to preserve the space adjacent to a newline, you can write `{'Monkeys: '}` or `Monkeys:{' '}` in your JSX source. We've included a script to do an automated codemod of your JSX source tree that preserves the old whitespace behavior by adding and removing spaces appropriately. You can [install jsx\_whitespace\_transformer from npm](https://github.com/facebook/react/blob/main/npm-jsx_whitespace_transformer/README.md) and run it over your source tree to modify files in place. The transformed JSX files will preserve your code's existing whitespace behavior.

## Changelog {#changelog}

Expand Down
2 changes: 1 addition & 1 deletion content/blog/2014-10-28-react-v0.12.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ As a result of this update, we no longer need to expose several internal modules

We updated the license on React to the BSD 3-Clause license with an explicit patent grant. Previously we used the Apache 2 license. These licenses are very similar and our extra patent grant is equivalent to the grant provided in the Apache license. You can still use React with the confidence that we have granted the use of any patents covering it. This brings us in line with the same licensing we use across the majority of our open source projects at Facebook.

You can read the full text of the [LICENSE](https://github.com/facebook/react/blob/master/LICENSE) and [`PATENTS`](https://github.com/facebook/react/blob/master/PATENTS) files on GitHub.
You can read the full text of the [LICENSE](https://github.com/facebook/react/blob/main/LICENSE) and [`PATENTS`](https://github.com/facebook/react/blob/main/PATENTS) files on GitHub.

- - -

Expand Down
2 changes: 1 addition & 1 deletion content/blog/2015-09-10-react-v0.14-rc1.md
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ And these two changes did not warn in 0.13 but should be easy to find and clean

- Due to the DOM node refs change mentioned above, `this.getDOMNode()` is now deprecated and `ReactDOM.findDOMNode(this)` can be used instead. Note that in most cases, calling `findDOMNode` is now unnecessary – see the example above in the “DOM node refs” section.

If you have a large codebase, you can use our [automated codemod script](https://github.com/facebook/react/blob/master/packages/react-codemod/README.md) to change your code automatically.
If you have a large codebase, you can use our [automated codemod script](https://github.com/facebook/react/blob/main/packages/react-codemod/README.md) to change your code automatically.

- `setProps` and `replaceProps` are now deprecated. Instead, call ReactDOM.render again at the top level with the new props.
- ES6 component classes must now extend `React.Component` in order to enable stateless function components. The [ES3 module pattern](/blog/2015/01/27/react-v0.13.0-beta-1.html#other-languages) will continue to work.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Prior to this release, we stripped out error messages at build-time and this is

> Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.

In order to make debugging in production easier, we're introducing an Error Code System in [15.2.0](https://github.com/facebook/react/releases/tag/v15.2.0). We developed a [script](https://github.com/facebook/react/blob/master/scripts/error-codes/extract-errors.js) that collects all of our `invariant` error messages and folds them to a [JSON file](https://github.com/facebook/react/blob/master/scripts/error-codes/codes.json), and at build-time Babel uses the JSON to [rewrite](https://github.com/facebook/react/blob/master/scripts/error-codes/transform-error-messages.js) our `invariant` calls in production to reference the corresponding error IDs. Now when things go wrong in production, the error that React throws will contain a URL with an error ID and relevant information. The URL will point you to a page in our documentation where the original error message gets reassembled.
In order to make debugging in production easier, we're introducing an Error Code System in [15.2.0](https://github.com/facebook/react/releases/tag/v15.2.0). We developed a [script](https://github.com/facebook/react/blob/main/scripts/error-codes/extract-errors.js) that collects all of our `invariant` error messages and folds them to a [JSON file](https://github.com/facebook/react/blob/main/scripts/error-codes/codes.json), and at build-time Babel uses the JSON to [rewrite](https://github.com/facebook/react/blob/main/scripts/error-codes/transform-error-messages.js) our `invariant` calls in production to reference the corresponding error IDs. Now when things go wrong in production, the error that React throws will contain a URL with an error ID and relevant information. The URL will point you to a page in our documentation where the original error message gets reassembled.

While we hope you don't see errors often, you can see how it works [here](/docs/error-decoder.html?invariant=109&args[]=Foo). This is what the same error from above will look like:

Expand Down
2 changes: 1 addition & 1 deletion content/blog/2016-11-16-react-v15.4.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ author: [gaearon]

Today we are releasing React 15.4.0.

We didn't announce the [previous](https://github.com/facebook/react/blob/master/CHANGELOG.md#1510-may-20-2016) [minor](https://github.com/facebook/react/blob/master/CHANGELOG.md#1520-july-1-2016) [releases](https://github.com/facebook/react/blob/master/CHANGELOG.md#1530-july-29-2016) on the blog because most of the changes were bug fixes. However, 15.4.0 is a special release, and we would like to highlight a few notable changes in it.
We didn't announce the [previous](https://github.com/facebook/react/blob/main/CHANGELOG.md#1510-may-20-2016) [minor](https://github.com/facebook/react/blob/main/CHANGELOG.md#1520-july-1-2016) [releases](https://github.com/facebook/react/blob/main/CHANGELOG.md#1530-july-29-2016) on the blog because most of the changes were bug fixes. However, 15.4.0 is a special release, and we would like to highlight a few notable changes in it.

### Separating React and React DOM {#separating-react-and-react-dom}

Expand Down
2 changes: 1 addition & 1 deletion content/blog/2017-05-18-whats-new-in-create-react-app.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ Newly created projects are built as [Progressive Web Apps](https://developers.go

New apps automatically have these features, but you can easily convert an existing project to a Progressive Web App by following [our migration guide](https://github.com/facebookincubator/create-react-app/releases/tag/v1.0.0).

We will be adding [more documentation](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#making-a-progressive-web-app) on this topic in the coming weeks. Please feel free to [ask any questions](https://github.com/facebookincubator/create-react-app/issues/new) on the issue tracker!
We will be adding [more documentation](https://github.com/facebookincubator/create-react-app/blob/main/packages/react-scripts/template/README.md#making-a-progressive-web-app) on this topic in the coming weeks. Please feel free to [ask any questions](https://github.com/facebookincubator/create-react-app/issues/new) on the issue tracker!


### Jest 20 {#jest-20}
Expand Down
2 changes: 1 addition & 1 deletion content/blog/2017-09-08-dom-attributes-in-react-16.md
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ Below is a detailed list of them.
React 15: Converts `NaN`s to strings and passes them through.
React 16: Converts `NaN`s to strings and passes them through with a warning.

While testing this release, we have also [created an automatically generated table](https://github.com/facebook/react/blob/master/fixtures/attribute-behavior/AttributeTableSnapshot.md) for all known attributes to track potential regressions.
While testing this release, we have also [created an automatically generated table](https://github.com/facebook/react/blob/main/fixtures/attribute-behavior/AttributeTableSnapshot.md) for all known attributes to track potential regressions.

## Try It! {#try-it}

Expand Down
Loading