Skip to content
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

chore(deps): update react monorepo to v18 (major) #47

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented May 15, 2021

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
react (source) 17.0.2 -> 18.3.1 age adoption passing confidence
react-test-renderer (source) 17.0.2 -> 18.3.1 age adoption passing confidence

Release Notes

facebook/react (react)

v18.3.1

Compare Source

v18.3.0

Compare Source

v18.2.0

Compare Source

React DOM
React DOM Server
Server Components (Experimental)

v18.1.0

Compare Source

React DOM
React DOM Server
ESLint Plugin: React Hooks
Use Subscription

v18.0.0

Compare Source

Below is a list of all new features, APIs, deprecations, and breaking changes.
Read React 18 release post and React 18 upgrade guide for more information.

New Features
React
  • useId is a new hook for generating unique IDs on both the client and server, while avoiding hydration mismatches. It is primarily useful for component libraries integrating with accessibility APIs that require unique IDs. This solves an issue that already exists in React 17 and below, but it’s even more important in React 18 because of how the new streaming server renderer delivers HTML out-of-order.
  • startTransition and useTransition let you mark some state updates as not urgent. Other state updates are considered urgent by default. React will allow urgent state updates (for example, updating a text input) to interrupt non-urgent state updates (for example, rendering a list of search results).
  • useDeferredValue lets you defer re-rendering a non-urgent part of the tree. It is similar to debouncing, but has a few advantages compared to it. There is no fixed time delay, so React will attempt the deferred render right after the first render is reflected on the screen. The deferred render is interruptible and doesn't block user input.
  • useSyncExternalStore is a new hook that allows external stores to support concurrent reads by forcing updates to the store to be synchronous. It removes the need for useEffect when implementing subscriptions to external data sources, and is recommended for any library that integrates with state external to React.
  • useInsertionEffect is a new hook that allows CSS-in-JS libraries to address performance issues of injecting styles in render. Unless you’ve already built a CSS-in-JS library we don’t expect you to ever use this. This hook will run after the DOM is mutated, but before layout effects read the new layout. This solves an issue that already exists in React 17 and below, but is even more important in React 18 because React yields to the browser during concurrent rendering, giving it a chance to recalculate layout.
React DOM Client

These new APIs are now exported from react-dom/client:

  • createRoot: New method to create a root to render or unmount. Use it instead of ReactDOM.render. New features in React 18 don't work without it.
  • hydrateRoot: New method to hydrate a server rendered application. Use it instead of ReactDOM.hydrate in conjunction with the new React DOM Server APIs. New features in React 18 don't work without it.

Both createRoot and hydrateRoot accept a new option called onRecoverableError in case you want to be notified when React recovers from errors during rendering or hydration for logging. By default, React will use reportError, or console.error in the older browsers.

React DOM Server

These new APIs are now exported from react-dom/server and have full support for streaming Suspense on the server:

  • renderToPipeableStream: for streaming in Node environments.
  • renderToReadableStream: for modern edge runtime environments, such as Deno and Cloudflare workers.

The existing renderToString method keeps working but is discouraged.

facebook/react (react-test-renderer)

v18.3.1

Compare Source

v18.3.0

Compare Source

v18.2.0

Compare Source

React DOM
React DOM Server
Server Components (Experimental)

v18.1.0

Compare Source

React DOM
React DOM Server
ESLint Plugin: React Hooks
Use Subscription

v18.0.0

Compare Source

Below is a list of all new features, APIs, deprecations, and breaking changes.
Read React 18 release post and React 18 upgrade guide for more information.

New Features
React
  • useId is a new hook for generating unique IDs on both the client and server, while avoiding hydration mismatches. It is primarily useful for component libraries integrating with accessibility APIs that require unique IDs. This solves an issue that already exists in React 17 and below, but it’s even more important in React 18 because of how the new streaming server renderer delivers HTML out-of-order.
  • startTransition and useTransition let you mark some state updates as not urgent. Other state updates are considered urgent by default. React will allow urgent state updates (for example, updating a text input) to interrupt non-urgent state updates (for example, rendering a list of search results).
  • useDeferredValue lets you defer re-rendering a non-urgent part of the tree. It is similar to debouncing, but has a few advantages compared to it. There is no fixed time delay, so React will attempt the deferred render right after the first render is reflected on the screen. The deferred render is interruptible and doesn't block user input.
  • useSyncExternalStore is a new hook that allows external stores to support concurrent reads by forcing updates to the store to be synchronous. It removes the need for useEffect when implementing subscriptions to external data sources, and is recommended for any library that integrates with state external to React.
  • useInsertionEffect is a new hook that allows CSS-in-JS libraries to address performance issues of injecting styles in render. Unless you’ve already built a CSS-in-JS library we don’t expect you to ever use this. This hook will run after the DOM is mutated, but before layout effects read the new layout. This solves an issue that already exists in React 17 and below, but is even more important in React 18 because React yields to the browser during concurrent rendering, giving it a chance to recalculate layout.
React DOM Client

These new APIs are now exported from react-dom/client:

  • createRoot: New method to create a root to render or unmount. Use it instead of ReactDOM.render. New features in React 18 don't work without it.
  • hydrateRoot: New method to hydrate a server rendered application. Use it instead of ReactDOM.hydrate in conjunction with the new React DOM Server APIs. New features in React 18 don't work without it.

Both createRoot and hydrateRoot accept a new option called onRecoverableError in case you want to be notified when React recovers from errors during rendering or hydration for logging. By default, React will use reportError, or console.error in the older browsers.

React DOM Server

These new APIs are now exported from react-dom/server and have full support for streaming Suspense on the server:

  • renderToPipeableStream: for streaming in Node environments.
  • renderToReadableStream: for modern edge runtime environments, such as Deno and Cloudflare workers.

The existing renderToString method keeps working but is discouraged.


Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about these updates again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@codecov-commenter
Copy link

codecov-commenter commented May 15, 2021

Codecov Report

Merging #47 (6b44508) into master (240b52b) will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##            master       #47   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            3         3           
  Lines           21        21           
  Branches         2         2           
=========================================
  Hits            21        21           

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@renovate renovate bot force-pushed the renovate/major-react-monorepo branch from fb46b4b to 88798ea Compare June 8, 2021 07:09
@renovate renovate bot changed the title Update react monorepo to v17 (major) Update react monorepo to v18 (major) Apr 25, 2022
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch from 88798ea to 38f063a Compare April 25, 2022 02:48
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch from 38f063a to 96c870a Compare May 15, 2022 21:46
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch from 96c870a to 38b4897 Compare June 18, 2022 17:58
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch from 38b4897 to 849d1b0 Compare September 25, 2022 12:32
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch from 849d1b0 to edfe7b2 Compare November 20, 2022 15:50
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch from edfe7b2 to 2ae8a81 Compare March 15, 2023 09:24
@renovate renovate bot changed the title Update react monorepo to v18 (major) chore(deps): update react monorepo to v18 (major) Mar 17, 2023
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch from 2ae8a81 to a4f787a Compare March 17, 2023 04:42
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 3 times, most recently from 6d8afe2 to bd5dba1 Compare March 28, 2023 22:19
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 2 times, most recently from e48cd7b to 5ca4545 Compare April 3, 2023 20:21
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 2 times, most recently from 8fc9f53 to 143a685 Compare April 12, 2023 12:47
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 2 times, most recently from 237862d to 2650450 Compare April 22, 2023 01:43
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch from 2650450 to 81a7180 Compare April 25, 2023 11:56
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 6 times, most recently from bf84ecd to 8f6faab Compare May 6, 2023 12:29
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 2 times, most recently from 07b465a to c5908e5 Compare June 1, 2023 20:17
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch from c5908e5 to 6bb731a Compare June 7, 2023 21:58
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 2 times, most recently from 853489d to 4c47f1f Compare July 31, 2023 23:27
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 2 times, most recently from 0dad154 to 6b44508 Compare August 9, 2023 19:47
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch from 6b44508 to d9db206 Compare August 22, 2023 21:40
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 4 times, most recently from 0de0da0 to c4c88e1 Compare October 1, 2023 13:59
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 3 times, most recently from 2c85d8c to 26c94b5 Compare October 10, 2023 19:40
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 3 times, most recently from 48b3cbf to ff6885a Compare October 20, 2023 15:27
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 2 times, most recently from 3b11a23 to 4b0ec78 Compare November 2, 2023 01:24
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 3 times, most recently from 3d3019b to 3972395 Compare November 7, 2023 21:29
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 2 times, most recently from 583b2e2 to a6b40e0 Compare November 27, 2023 23:13
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch from a6b40e0 to b1eedfa Compare November 29, 2023 09:54
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch 4 times, most recently from ef44bc6 to d3a40d2 Compare February 14, 2024 04:28
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch from d3a40d2 to 1f4ab8c Compare April 25, 2024 17:50
@renovate renovate bot force-pushed the renovate/major-react-monorepo branch from 1f4ab8c to 84da410 Compare April 26, 2024 17:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant