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

Not working on latest React 18 version #684

Open
elenaaleksovska-rldatix opened this issue Sep 5, 2022 · 7 comments
Open

Not working on latest React 18 version #684

elenaaleksovska-rldatix opened this issue Sep 5, 2022 · 7 comments

Comments

@elenaaleksovska-rldatix
Copy link

elenaaleksovska-rldatix commented Sep 5, 2022

Hello, I tried to upgrade to react 18.

These are the npm react packages that I am using:
"react": "^18.2.0",
"react-document-title": "^2.0.3",
"react-dom": "^18.2.0",
"react-router-dom": "^5.3.3",
"react-select": "^5.4.0"

when I delete node_modules and run npm install these are the errors I get:

image

Any suggestions?

@GhostyJade
Copy link

Can you try to add to your package.json peer dependency section your react (and react-dom) current package and version?
Something like

  "peerDependencies": {
    "react": "18.2.0",
    "react-dom": "18.2.0"
  }

@elenaaleksovska-rldatix
Copy link
Author

elenaaleksovska-rldatix commented Sep 15, 2022

I've tried, I got the same errors as in the screenshot.

@GhostyJade
Copy link

GhostyJade commented Sep 15, 2022 via email

@AbdaliDahir
Copy link

formsy accept only : ^16.0.0 || ^17.0.0 (check package).
for now maybe u can use ==> npm config set legacy-peer-deps true.
more information :
https://stackoverflow.com/questions/66239691/what-does-npm-install-legacy-peer-deps-do-exactly-when-is-it-recommended-wh

@felixmosh
Copy link
Contributor

Can you test v2.3.0 version which added React 18 as peerDeps

@AbdaliDahir
Copy link

@felixmosh Yup it works.
tested with ( React 18.2.0 - node v16.17.0 - npm v8.15.0 - formsy v2.3.0).

@felixmosh
Copy link
Contributor

Great, the installation is working.
Can you check if there are any other issues?

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

No branches or pull requests

4 participants