Doesn't provide peer deps when using Yarn v2
See original GitHub issue[REQUIRED] Describe your environment
- Operating System version: Ubuntu 18.04.2 (64-bit)
- Browser version: Firefox 78.0.1 (64-bit)
- Firebase SDK version: 7.17.1
- Firebase Product: database and auth
[REQUIRED] Describe the problem
This doesn’t support Yarn v2 because some of the @firebase
packages don’t provide their dependent’s peer dependencies (e.g. @firebase/auth
doesn’t provide @firebase/util
which is requested by @firebase/auth-types
).
You should:
- Add the
@firebase/app-types
as a peer dependency to@firebase/database
and@firebase/auth
- Add the
@firebase/util
as a peer dependency to@firebase/auth
Steps to reproduce:
- Clone this repository by running:
$ git clone https://github.com/tutorbookapp/tutorbook
- Check out to
develop
and fetch the latest changes:
$ git checkout develop && git pull
- Make sure you have Yarn installed and then run:
$ yarn install
- Notice that there are warnings about
@firebase/database
and@firebase/auth
not providing their dependency’s peer dependencies:
➤ YN0002: │ @firebase/database@npm:0.6.9 doesn't provide @firebase/app-types@0.x requested by @firebase/auth-interop-types@npm:0.1.5
➤ YN0002: │ @firebase/auth@npm:0.14.9 [387e6] doesn't provide @firebase/app-types@0.x requested by @firebase/auth-types@npm:0.10.1
➤ YN0002: │ @firebase/auth@npm:0.14.9 [387e6] doesn't provide @firebase/util@0.x requested by @firebase/auth-types@npm:0.10.1
Issue Analytics
- State:
- Created 3 years ago
- Comments:8 (2 by maintainers)
Top Results From Across the Web
Doesn't provide peer deps when using Yarn v2 #3529 - GitHub
This doesn't support Yarn v2 because some of the @firebase packages don't provide their dependent's peer dependencies (e.g. @firebase/auth doesn ...
Read more >Migrating to Yarn 2 and solve peer dependencies
I'm trying to upgrade a project to use Yarn 2 instead of the classic version. I've followed the migration guide here.
Read more >Types of dependencies | Yarn
Having a peer dependency means that your package needs a dependency that is the same exact dependency as the person installing your package....
Read more >npm, pnpm, and Yarn | IntelliJ IDEA Documentation - JetBrains
IntelliJ IDEA integrates with the npm, Yarn, Yarn 2, and pnpm, ... you handle your project dependencies in package.json files providing ...
Read more >Managing dependencies - AWS Documentation
If you prefer, you may use Yarn in place of NPM. However, the CDK does not support Yarn's plug-and-play mode, which is default...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Seems still not fixed yet. Using pnpm here.
Temporary fix is to use the
packageExtensions
config in.yarnrc.yml
(see docs):Once I did that, I got a warning about
firebase-admin
:So, I added that to the
packageExtensions
as well:And it looks fine now.