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

Use @googlemaps/js-api-loader as a peer dependency #782

Open
cgarrovillo opened this issue Feb 16, 2024 · 3 comments
Open

Use @googlemaps/js-api-loader as a peer dependency #782

cgarrovillo opened this issue Feb 16, 2024 · 3 comments
Labels
priority: p1 Important issue which blocks shipping the next release. Will be fixed prior to next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.

Comments

@cgarrovillo
Copy link

@googlemaps/js-api-loader should be used as a peer dependency due to issues like this.

googlemaps/js-api-loader#825

Using this as a dependency expands the blast radius of the dependencies of this package.

@cgarrovillo cgarrovillo added triage me I really want to be triaged. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns. labels Feb 16, 2024
@wangela
Copy link
Member

wangela commented Feb 16, 2024

If you would like to upvote the priority of this issue, please comment below or react on the original post above with 👍 so we can see what is popular when we triage.

@cgarrovillo Thank you for opening this issue. 🙏
Please check out these other resources that might help you get to a resolution in the meantime:

This is an automated message, feel free to ignore.

@IsraelVazquezEsparza
Copy link

@cgarrovillo Thanks. It works!

@wangela wangela added priority: p1 Important issue which blocks shipping the next release. Will be fixed prior to next release. and removed triage me I really want to be triaged. labels Feb 16, 2024
@usefulthink
Copy link
Contributor

I don't think that would have helped much, and most of the time - when dependencies aren't broken - it would only make it more complicated to install this package.

What happened last week was a published version of @googlemaps/js-api-loader that was broken. That would have had mostly the same effect if it was installed as a peer-dependency instead of a transitive dependency.

The only thing you can do in such a situation is to pin the dependency to an older version, and that can be done for both peerDependencies as well as for transitive dependencies (by specifying a resolution for the package in the package.json).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority: p1 Important issue which blocks shipping the next release. Will be fixed prior to next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Projects
None yet
Development

No branches or pull requests

4 participants