diff --git a/flow-server/src/main/java/com/vaadin/flow/server/frontend/FrontendTools.java b/flow-server/src/main/java/com/vaadin/flow/server/frontend/FrontendTools.java index 7ba59694a98..13197e4e0e9 100644 --- a/flow-server/src/main/java/com/vaadin/flow/server/frontend/FrontendTools.java +++ b/flow-server/src/main/java/com/vaadin/flow/server/frontend/FrontendTools.java @@ -981,6 +981,7 @@ private List getNpmExecutable(boolean removePnpmLock) { returnCommand.add("--no-update-notifier"); returnCommand.add("--no-audit"); returnCommand.add("--scripts-prepend-node-path=true"); + returnCommand.add("--legacy-peer-deps"); if (removePnpmLock) { // remove pnpm-lock.yaml which contains pnpm as a dependency. diff --git a/flow-server/src/main/resources/com/vaadin/flow/server/frontend/dependencies/react-router/package.json b/flow-server/src/main/resources/com/vaadin/flow/server/frontend/dependencies/react-router/package.json index f8e12df26d9..679f854558a 100644 --- a/flow-server/src/main/resources/com/vaadin/flow/server/frontend/dependencies/react-router/package.json +++ b/flow-server/src/main/resources/com/vaadin/flow/server/frontend/dependencies/react-router/package.json @@ -9,8 +9,8 @@ "author": "", "license": "Apache-2.0", "dependencies": { - "react": "18.3.1", - "react-dom": "18.3.1", + "react": "19.0.0-rc-3563387fe3-20240621", + "react-dom": "19.0.0-rc-3563387fe3-20240621", "react-router-dom": "6.23.1" }, "devDependencies": { diff --git a/flow-server/src/test/java/com/vaadin/flow/server/frontend/FrontendToolsTest.java b/flow-server/src/test/java/com/vaadin/flow/server/frontend/FrontendToolsTest.java index 98357e3f513..3c88d15a9b6 100644 --- a/flow-server/src/test/java/com/vaadin/flow/server/frontend/FrontendToolsTest.java +++ b/flow-server/src/test/java/com/vaadin/flow/server/frontend/FrontendToolsTest.java @@ -417,7 +417,7 @@ public void homeNodeIsNotForced_useGlobalNode() not(containsString(vaadinHomeDir))); assertThat(tools.getNodeExecutable(), not(containsString(baseDir))); - assertEquals(4, tools.getNpmExecutable().size()); + assertEquals(5, tools.getNpmExecutable().size()); assertThat(tools.getNpmExecutable().get(0), containsString("npm")); assertThat(tools.getNpmExecutable().get(1), containsString("--no-update-notifier"));