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

Support for react version 17.0.1 #1503

Open
Susan123456789 opened this issue Nov 5, 2020 · 9 comments · May be fixed by #1723
Open

Support for react version 17.0.1 #1503

Susan123456789 opened this issue Nov 5, 2020 · 9 comments · May be fixed by #1723
Assignees

Comments

@Susan123456789
Copy link

Describe the bug
Unable to install react-bootstrap-table-next on the latest create-react-app which uses react 17.0.1:

To Reproduce
Steps to reproduce the behavior:

  1. npx create-react-app example
  2. cd example
  3. npm install react-bootstrap-table-next --save
  4. See error:
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: example@0.1.0
npm ERR! Found: react@17.0.1
npm ERR! node_modules/react
npm ERR!   react@"^17.0.1" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react@"^16.3.0" from react-bootstrap-table-next@4.0.3
npm ERR! node_modules/react-bootstrap-table-next
npm ERR!   react-bootstrap-table-next@"*" 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.
@MLazarevic36
Copy link

MLazarevic36 commented Apr 1, 2021

Hello, has anyone found solution for this? I mean, is it safe to install with --legacy-peer-deps?

@risingsunomi
Copy link

risingsunomi commented Jun 3, 2021

Hello, has anyone found solution for this? I mean, is it safe to install with --legacy-peer-deps?

I have just tried it and it seems to give me some security issues but seems to install.

$ npm install react-bootstrap-table-next --save --force
npm WARN using --force Recommended protections disabled.
npm WARN ERESOLVE overriding peer dependency
npm WARN Found: react@17.0.2
npm WARN node_modules/react
npm WARN peer react@">=0.14.0" from @hypnosphi/create-react-context@0.3.1
npm WARN node_modules/@hypnosphi/create-react-context
npm WARN @hypnosphi/create-react-context@"^0.3.1" from react-popper@1.3.11
npm WARN node_modules/react-popper
npm WARN 7 more (@testing-library/react, react-dom, react-popper, ...)
npm WARN
npm WARN Could not resolve dependency:
npm WARN peer react@"^16.3.0" from react-bootstrap-table-next@4.0.3
npm WARN node_modules/react-bootstrap-table-next
npm WARN react-bootstrap-table-next@"" from the root project
npm WARN ERESOLVE overriding peer dependency
npm WARN Found: react-dom@17.0.2
npm WARN node_modules/react-dom
npm WARN peer react-dom@"
" from @testing-library/react@11.2.6
npm WARN node_modules/@testing-library/react
npm WARN @testing-library/react@"^11.2.6" from the root project
npm WARN 3 more (react-transition-group, reactstrap, the root project)
npm WARN
npm WARN Could not resolve dependency:
npm WARN peer react-dom@"^16.3.0" from react-bootstrap-table-next@4.0.3
npm WARN node_modules/react-bootstrap-table-next
npm WARN react-bootstrap-table-next@"*" from the root project

I then audited the install and got a high level warning from the install of underscores with the table-next

underscore 1.3.2 - 1.12.0
Severity: high
Arbitrary Code Execution - https://npmjs.com/advisories/1674
fix available via npm audit fix --force
Will install react-bootstrap-table-next@1.1.0, which is a breaking change
node_modules/underscore
react-bootstrap-table-next >=1.1.1
Depends on vulnerable versions of underscore
node_modules/react-bootstrap-table-next

Which just suggests to downgrade to 1.1.0. I don't think there is any breaking changes to the table-next library with react 17.0.2 from 16.3.0 but will explore any issues I find and post here. I think the package.json just needs to be updated for the library.

@Avasam
Copy link

Avasam commented Jun 23, 2021

It works for me (you can take a look at my package.json. However it does throw a lot of missing peer dependencies warnings:

npm WARN @babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@7.13.12 requires a peer of @babel/core@^7.13.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table-next@4.0.3 requires a peer of react@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table-next@4.0.3 requires a peer of react-dom@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table2-filter@1.3.3 requires a peer of react@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table2-filter@1.3.3 requires a peer of react-dom@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table2-paginator@2.1.2 requires a peer of react@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table2-paginator@2.1.2 requires a peer of react-dom@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table2-toolkit@2.1.3 requires a peer of react@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table2-toolkit@2.1.3 requires a peer of react-dom@^16.3.0 but none is installed. You must install peer dependencies yourself.

@risingsunomi
Copy link

It works for me (you can take a look at my package.json. However it does throw a lot of missing peer dependencies warnings:

npm WARN @babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@7.13.12 requires a peer of @babel/core@^7.13.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table-next@4.0.3 requires a peer of react@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table-next@4.0.3 requires a peer of react-dom@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table2-filter@1.3.3 requires a peer of react@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table2-filter@1.3.3 requires a peer of react-dom@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table2-paginator@2.1.2 requires a peer of react@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table2-paginator@2.1.2 requires a peer of react-dom@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table2-toolkit@2.1.3 requires a peer of react@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap-table2-toolkit@2.1.3 requires a peer of react-dom@^16.3.0 but none is installed. You must install peer dependencies yourself.

Yes, seen the same but the package is working after forcing the install. Doesn't seem to break with new react. If, in the future, this project won't be updated to new react, the community might need to fork it and keep it up to date

@pavanshinde81
Copy link

@AllenFang can you please update the react version?

@bcamarneiro bcamarneiro linked a pull request Feb 17, 2022 that will close this issue
@thebrandonlucas
Copy link

thebrandonlucas commented Mar 3, 2022

Like @risingsunomi I also forced the install with npm install react-bootstrap-table-next --legacy-peer-deps and the component seems to be working fine for me as well, so I think once @camarneiro's pull request gets merged in a normal install will work.

@mmelilli
Copy link

any news about the update of react version?

@201flaviosilva
Copy link

201flaviosilva commented Jun 2, 2022

Like @risingsunomi I also forced the install with npm install react-bootstrap-table-next --legacy-peer-deps and the component seems to be working fine for me as well, so I think once @camarneiro's pull request gets merged in a normal install will work.

Work for me, but I think, it’s good to fix that in a better way :)

@bartektartanus
Copy link

Looks like musicstory fork of this package is updated to react v17.
https://www.npmjs.com/~musicstory

    "@musicstory/react-bootstrap-table-next": "^1.0.5",
    "@musicstory/react-bootstrap-table2-editor": "^1.0.1",
    "@musicstory/react-bootstrap-table2-filter": "^1.0.1",

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

Successfully merging a pull request may close this issue.

10 participants