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

Fix package.json should mention peer dependency on react-is #9201

Merged
merged 4 commits into from
Aug 22, 2023

Conversation

kamiyo
Copy link
Contributor

@kamiyo kamiyo commented Aug 21, 2023

https://github.com/marmelab/react-admin/blob/83dc1d61f0d7efaafebb57885d6b55f78509b581/packages/ra-ui-materialui/src/form/FormTabHeader.tsx has an import from react-is, but it is not declared in package.json

This was causing errors in my rollup build. I cannot be sure this is the right fix - for my project, I had to add this in my .yarmrc.yml:

packageExtensions:
  "ra-ui-materialui@*":
    dependencies:
      "react-is": "*"

Here, peerDependencies doesn't work, but for package.json I think it makes sense to put it there.

https://github.com/marmelab/react-admin/blob/83dc1d61f0d7efaafebb57885d6b55f78509b581/packages/ra-ui-materialui/src/form/FormTabHeader.tsx has an import from `react-is`, but it is not declared in `package.json`

This was causing errors in my rollup build. I cannot be sure this is the right fix - for my project, I had to add this in my `.yarmrc.yml`:

```
packageExtensions:
  "ra-ui-materialui@*":
    dependencies:
      "react-is": "*"
```
Here, `peerDependencies` doesn't work, but for `package.json` I think it makes sense to put it there.
Copy link
Collaborator

@djhi djhi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Can you please commit the updated yarn.lock as well?

@kamiyo
Copy link
Contributor Author

kamiyo commented Aug 22, 2023

Hrm, the yarn update updated some other dependencies at all. Is that okay, or do I somehow have to cherry pick just the react-is addition under ra-ui-materialui?

@slax57
Copy link
Contributor

slax57 commented Aug 22, 2023

I took the liberty to update your branch, and fix the yarn.lock file (by running make install).
Should be good now.

@slax57 slax57 added this to the 4.13.2 milestone Aug 22, 2023
@slax57 slax57 merged commit 56ec288 into marmelab:master Aug 22, 2023
7 checks passed
@slax57 slax57 changed the title Update package.json Fix package.json should mention peer dependency on react-is Aug 22, 2023
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 this pull request may close these issues.

3 participants