-
Notifications
You must be signed in to change notification settings - Fork 17
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
playwright-core vs playwright as peerDependency #65
Comments
We need
expect-playwright/package.json Lines 14 to 16 in 6a1d637
Or do you mean on Playwright side? |
I meant why is this not ok? "peerDependencies": {
"playwright": "^1.9.1"
}, The current solution with requiring Any user using |
This example would install playwright all the time which installs all the browsers on all the users environments. We want to prevent that and when a user is installing playwright-chromium that only chromium gets installed. Yep this is unfortunately the pitfall that the user needs to have two packages of playwright there but unfortunately the only solution to workaround that problem. |
Isn't it necessary though for a user to already have the But I recon that 99% of users already have (I'll admit techincally it is more correct for you to have |
Jumping in as a user who uses playwright-chromium, having the peer dep as |
Is there a reason that |
@thernstig Using a flag such as
|
Maybe I am wrong here. But the problem I find is that a user that installs Mind you I am just trying to find the best option here for the majority of users. And I might be completely incorrect in my assumptions and recommendations, but I have not see other packages doing it like this before hence why it jumped at me as a bit "off". |
I'll grant this point any day. Most users definitely use the playwright package, however those who use the specific browser packages should also be supported.
Definitely an option, but requiring users to set environment variables to use a package is not a good experience.
You are correct, if a user installs The really unfortunate part of this whole conversation is that the only usage of |
@mxschmitt Just got to thinking, but is there any downsides to installing |
Installing it as a regular dependency still gets into the trouble of differeing versions between users normal I am still a believer that
This is not required by most users. Actually, it is not required by any user. I'd say your use case is the outlier here and there is a much bigger problem with a missmatch between users |
Right, but thinking more about it, that should be fine since
How is it not required by any user? It would be for users like me.
This repository is actually another place that doesn't use https://github.com/playwright-community/expect-playwright/blob/master/package.json#L22-L23 |
Currently I have to install both playwright and playwright-core in my package.json in order to run expect-playwright.
If I compare the subdependencies of playwright and playwright-core, they are identical. How come playwright could not be listed as the peer dependency instead?
The text was updated successfully, but these errors were encountered: