Bumps the upper limit for react as a peer dependency of the components package. I think this should override the peer dependency in carbon components' 10/7 branch. React 18 shouldn't break anything functionally, but this change allows an app consuming discovery components and using react 18 to build successfully.
How do you test/verify these changes?
Checkout this branch locally, run yarn to install the latest package changes
Run yarn why react and see that the components themselves are still pulling in react 17
In the components package directory, run yarn dlx yalc publish --push to create a build and push it to a local repository that's linkable in tooling.
If the build fails here, you may need to delete node_modules in either the root or components directory and then rerun yarn
In tooling's client directory, run yarn dlx yalc add @ibm-watson/discovery-react-components to link the components build locally
In tooling's client/package.json, change react and react-dom to "^18.2.0", run yarn, and then verify with yarn why react that react 18 is the version being used
Run tooling locally with yarn run start and yarn run api:cloud. Verify that everything builds, and the react components haven't broken (like by running a query and checking the results)
Have you documented your changes (if necessary)?
N/A
Are there any breaking changes included in this pull request?
What do these changes do/fix?
Implementation for https://github.ibm.com/Watson-Discovery/disco-issue-tracker/issues/18222
Bumps the upper limit for react as a peer dependency of the components package. I think this should override the peer dependency in carbon components' 10/7 branch. React 18 shouldn't break anything functionally, but this change allows an app consuming discovery components and using react 18 to build successfully.
How do you test/verify these changes?
yarn
to install the latest package changesyarn why react
and see that the components themselves are still pulling in react 17yarn dlx yalc publish --push
to create a build and push it to a local repository that's linkable in tooling.node_modules
in either the root or components directory and then rerunyarn
yarn dlx yalc add @ibm-watson/discovery-react-components
to link the components build locallyclient/package.json
, changereact
andreact-dom
to "^18.2.0", runyarn
, and then verify withyarn why react
that react 18 is the version being usedyarn run start
andyarn run api:cloud
. Verify that everything builds, and the react components haven't broken (like by running a query and checking the results)Have you documented your changes (if necessary)?
N/A
Are there any breaking changes included in this pull request?
No