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

Adds react-dom and react-native as optional peer dependencies #1425

Closed

Conversation

arcanis
Copy link

@arcanis arcanis commented Oct 14, 2019

This diff adds react-dom and react-native as optional peer dependencies.

The react-redux package currently published doesn't list them, which is invalid. For example, here's what Yarn v2 is throwing:

image

Optional peer dependencies are supported by all three package managers and will silence warning that would otherwise appear if a consumer was omitting them.

@netlify
Copy link

netlify bot commented Oct 14, 2019

Deploy preview for react-redux-docs ready!

Built with commit 0ad60d9

https://deploy-preview-1425--react-redux-docs.netlify.com

@timdorr
Copy link
Member

timdorr commented Oct 14, 2019

See these PRs:

#1261
#1282
#1371
#1366

@timdorr timdorr closed this Oct 14, 2019
@timdorr
Copy link
Member

timdorr commented Oct 14, 2019

Whoops, this is actually a dupe of #1390

@arcanis
Copy link
Author

arcanis commented Oct 14, 2019

@timdorr I'm about to merge a PR in Yarn to make peerDependenciesMeta imply peerDependencies (only for Yarn). This should make it possible to remove the warning in both Yarn and npm. Would that be acceptable?

@timdorr
Copy link
Member

timdorr commented Oct 14, 2019

If we can leave it out of peerDeps still, that would be great!

The concern I have is for those that haven't yet upgraded their client. npm 6.11 has only been bundled with node for a few weeks now and obviously isn't available on an LTS release yet. For those users, adding the peerDep would make it warn on install.

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.

None yet

2 participants