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

When installing this dependency using react 17 #79

Open
Alexie81 opened this issue May 3, 2023 · 2 comments
Open

When installing this dependency using react 17 #79

Alexie81 opened this issue May 3, 2023 · 2 comments

Comments

@Alexie81
Copy link

Alexie81 commented May 3, 2023

It would be great if this could work with versions later than 16.

npm install @unicef/material-ui-currency-textfield --save

npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR! 
npm ERR! While resolving: MY_REPO
npm ERR! Found: [email protected]
npm ERR! node_modules/react
npm ERR!   react@"^17.0.2" from the root project
npm ERR!   peer react@"^16.8.0 || ^17.0.0" from @material-ui/[email protected]
npm ERR!   node_modules/@material-ui/core
npm ERR!     peer @material-ui/core@">= 4.3.0" from @unicef/[email protected]
npm ERR!     node_modules/@unicef/material-ui-currency-textfield
npm ERR!       @unicef/material-ui-currency-textfield@"*" from the root project
npm ERR!   1 more (react-dom)
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer react@"^16.8.6" from @unicef/[email protected]
npm ERR! node_modules/@unicef/material-ui-currency-textfield
npm ERR!   @unicef/material-ui-currency-textfield@"*" from the root project
npm ERR! 
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
@IvarK
Copy link

IvarK commented Dec 13, 2023

Adding this to package.json works for me

"overrides": {
    "@unicef/material-ui-currency-textfield": {
      "react": "^17.0.0",
      "react-dom": "^17.0.0"
    }
  }

@MiLandry
Copy link

Not having luck with that approach. getting

Module not found: Can't resolve '@material-ui/styles'

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

3 participants