From d67b71dd25d457a2a59f2c943db13f50fab7ec3d Mon Sep 17 00:00:00 2001 From: David Khourshid Date: Mon, 28 Oct 2024 09:55:54 -0400 Subject: [PATCH] Add peer dependency support for React 19 (#5109) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Add peer dependency support for React 19 * Changeset * Update packages/xstate-react/package.json Co-authored-by: Mateusz Burzyński * Update packages/xstate-store/package.json Co-authored-by: Mateusz Burzyński --------- Co-authored-by: Mateusz Burzyński --- .changeset/four-countries-serve.md | 6 ++++++ packages/xstate-react/package.json | 2 +- packages/xstate-store/package.json | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) create mode 100644 .changeset/four-countries-serve.md diff --git a/.changeset/four-countries-serve.md b/.changeset/four-countries-serve.md new file mode 100644 index 0000000000..3a8c5f4b88 --- /dev/null +++ b/.changeset/four-countries-serve.md @@ -0,0 +1,6 @@ +--- +'@xstate/react': patch +'@xstate/store': patch +--- + +Add React 19 as a peer dependency diff --git a/packages/xstate-react/package.json b/packages/xstate-react/package.json index 9417648228..fa92bd0dd2 100644 --- a/packages/xstate-react/package.json +++ b/packages/xstate-react/package.json @@ -54,7 +54,7 @@ "url": "https://github.com/statelyai/xstate/issues" }, "peerDependencies": { - "react": "^16.8.0 || ^17.0.0 || ^18.0.0", + "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0-0", "xstate": "workspace:^" }, "peerDependenciesMeta": { diff --git a/packages/xstate-store/package.json b/packages/xstate-store/package.json index ef2b93cf34..45d3494253 100644 --- a/packages/xstate-store/package.json +++ b/packages/xstate-store/package.json @@ -69,7 +69,7 @@ "xstate": "workspace:^" }, "peerDependencies": { - "react": "^18.2.0", + "react": "^18.2.0 || ^19.0.0-0", "solid-js": "^1.7.6" }, "peerDependenciesMeta": {