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

ui-lib: most peerdeps should be a dependency #2624

Open
jschuler opened this issue Jun 27, 2024 · 3 comments
Open

ui-lib: most peerdeps should be a dependency #2624

jschuler opened this issue Jun 27, 2024 · 3 comments

Comments

@jschuler
Copy link
Contributor

jschuler commented Jun 27, 2024

in OCM (currently trying to switch to npm):

ERROR in ./node_modules/@openshift-assisted/ui-lib/build/cjs/common/components/ui/formik/LabelField.js 8:50-76

Module not found: Error: Can't resolve 'react-tagsinput' in '/container_workspace/node_modules/@openshift-assisted/ui-lib/build/cjs/common/components/ui/formik'

Same for @sentry/browser, 'axios', monaco-editor, etc...

Looking at the package.json file

"peerDependencies": {
    "@reduxjs/toolkit": "^1.9.1",
    "@sentry/browser": "^5.9 || ^6",
    "axios": ">=0.22.0 <1.0.0",
    "i18next": "^20.4 || ^21",
    "monaco-editor": "0.45.0",
    "react": "^17 || ^18",
    "react-dom": "^17 || ^18",
    "react-i18next": ">11.7.3",
    "react-monaco-editor": "^0.55.0",
    "react-redux": "^8.0.5",
    "react-router-dom": "^5.3.0",
    "react-tagsinput": "^3.20",
    "redux": "^4",
    "uuid": "^8.1",
    "yup": "^1.4.0"
  },

Most of these should be dependencies apart from react and react-dom

@jschuler jschuler changed the title ui-lib: react-tagsinput should be a dependency ui-lib: most peerdeps should be a dependency Jun 27, 2024
@ammont82
Copy link
Contributor

Now I'm working in a MR to solve problems wit dependencies: #2621
I can include these changes also.

@jschuler
Copy link
Contributor Author

@ammont82 I have a branch here https://gitlab.cee.redhat.com/service/uhc-portal/-/merge_requests/5699 if you remove the overrides in package.json and run npm install you will see them

@ammont82
Copy link
Contributor

i'll try it on Monday. Thanks!

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

2 participants