Npm install force

When I try to deploy my React 19 (beta) site, I’ll get this

==> Installing dependencies with npm...

Apr 30 08:37:18 PMnpm ERR! code ERESOLVE

Apr 30 08:37:18 PMnpm ERR! ERESOLVE could not resolve

Apr 30 08:37:18 PMnpm ERR!

Apr 30 08:37:18 PMnpm ERR! While resolving: @tanstack/react-query@5.29.2

Apr 30 08:37:18 PMnpm ERR! Found: react@19.0.0-beta-94eed63c49-20240425

Apr 30 08:37:18 PMnpm ERR! node_modules/react

Apr 30 08:37:18 PMnpm ERR! react@"^19.0.0-beta-94eed63c49-20240425" from the root project

Apr 30 08:37:18 PMnpm ERR! peer react@"19.0.0-beta-94eed63c49-20240425" from react-dom@19.0.0-beta-94eed63c49-20240425

Apr 30 08:37:18 PMnpm ERR! node_modules/react-dom

Apr 30 08:37:18 PMnpm ERR! react-dom@"^19.0.0-beta-94eed63c49-20240425" from the root project

Apr 30 08:37:18 PMnpm ERR!

Apr 30 08:37:18 PMnpm ERR! Could not resolve dependency:

Apr 30 08:37:18 PMnpm ERR! peer react@"^18.0.0" from @tanstack/react-query@5.29.2

Apr 30 08:37:18 PMnpm ERR! node_modules/@tanstack/react-query

Apr 30 08:37:18 PMnpm ERR! @tanstack/react-query@"^5.29.2" from the root project

Apr 30 08:37:18 PMnpm ERR! peer @tanstack/react-query@"^5.29.2" from @tanstack/react-query-devtools@5.29.2

Apr 30 08:37:18 PMnpm ERR! node_modules/@tanstack/react-query-devtools

Apr 30 08:37:18 PMnpm ERR! @tanstack/react-query-devtools@"^5.29.2" from the root project

Apr 30 08:37:18 PMnpm ERR!

Apr 30 08:37:18 PMnpm ERR! Conflicting peer dependency: react@18.3.1

Apr 30 08:37:18 PMnpm ERR! node_modules/react

Apr 30 08:37:18 PMnpm ERR! peer react@"^18.0.0" from @tanstack/react-query@5.29.2

Apr 30 08:37:18 PMnpm ERR! node_modules/@tanstack/react-query

Apr 30 08:37:18 PMnpm ERR! @tanstack/react-query@"^5.29.2" from the root project

Apr 30 08:37:18 PMnpm ERR! peer @tanstack/react-query@"^5.29.2" from @tanstack/react-query-devtools@5.29.2

Apr 30 08:37:18 PMnpm ERR! node_modules/@tanstack/react-query-devtools

Apr 30 08:37:18 PMnpm ERR! @tanstack/react-query-devtools@"^5.29.2" from the root project

Apr 30 08:37:18 PMnpm ERR!

Apr 30 08:37:18 PMnpm ERR! Fix the upstream dependency conflict, or retry

Apr 30 08:37:18 PMnpm ERR! this command with --force or --legacy-peer-deps

Apr 30 08:37:18 PMnpm ERR! to accept an incorrect (and potentially broken) dependency resolution.

Apr 30 08:37:18 PMnpm ERR!

Because of that, I want to force-install the dependencies. However it seems to ignore the --force flag on it.

In the deloy-settings it is set to

npm i --force; npm run build:no-tsc

Is this just not supported or do I need to format it to some other format?

Best regards.

The only thing I can think is wrong here would be that you aren’t using two plain --s. For example, on macOS by default when you type -- in many standard text apps they are converted into an em-dash (). Coincidentally, even on this forum I had to code guard them because this is two dashes: – , even it is transforming them into an em-dash. Note that this forum is third-party software and not written by Render, and this shouldn’t happen on the Render Dashboard’s form fields, but if you typed them in somewhere else and copy/pasted them into the Render Dashboard they may be the wrong type.

Characters are a wild world. What looks like - could be a hyphen, a minus, an en-dash, an em-dash, and probably even more types that I’m not thinking of. Try deleting what you have for the Build Command in the Render Dashboard and re-typing it character by character, and ensure that it is not altered in the process, via auto-complete, or a browser plugin (ala. Grammarly), or anything else of that sort.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.