-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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: add undeclared dependencies and resolve others (fix #8286, fix #7581) #10277
Conversation
The template/project should use a reference comment in `env.d.ts`, otherwise other types are blocked
Hi @merceyz and thanks for the contribution, can you clarify some aspects of this PR? In particular:
You marked this as not breaking change, but it seems to be, at least at a conceptual level |
Sorry about that, I should have opened it as a draft. I've updated the PR to explain what's going on. |
About As far as I can understand, the docs examples showing how to extend the webpack chain into the project On the other hand, it's correct to use it into AE docs and put there a note about using Am I wrong on these assumptions? |
Btw, I'm still not sure about this, as it happened quite some times to rely on hoisting when testing new packages versions before updating it into I guess we can obtain a similar result using yarn resolutions, but I'm not sure it would work the same |
Correct.
I replaced all instances I found though those can probably be reverted but doesn't hurt to keep it.
If you're referring to quasarframework/quasar-starter-kit@113dacc then it is actually, |
Just a little update: we didn't forget about this PR, we're discussing about this |
Hi, I appreciate the contribution. However, this is a "no-go" for several reasons:
There are other things that need a note here, but this post is getting ridiculously long. |
What kind of change does this PR introduce? (check at least one)
Does this PR introduce a breaking change? (check one)
The PR fulfills these requirements:
dev
branch (orv[X]
branch)fix: #xxx[,#xxx]
, where "xxx" is the issue number)Other information:
Fixes #8286
Fixes #7581
Ref quasarframework/quasar-starter-kit#159
In order to not rely on unpredictable hoisting this PR makes a few changes.
require.resolve
Webpack loadersSee https://github.com/yarnpkg/berry/tree/b605eaf5785dc91d0f5248da67ec9f34460900ca/packages/yarnpkg-doctor#no-unqualified-webpack-config
Declare dependencies
See https://yarnpkg.com/advanced/rulebook#packages-should-only-ever-require-what-they-formally-list-in-their-dependencies
types
intsconfig.json
Using the
types
option intsconfig.json
disables the default behaviour of loading all visible types in the global scope, this PR avoids using it and instead uses a triple-slash directive to avoid disabling that behaviourhttps://www.typescriptlang.org/tsconfig#types
https://www.typescriptlang.org/docs/handbook/triple-slash-directives.html#-reference-types-
Making
vue
andvue-router
peer dependenciesvue
is currently a dependency of@quasar/app
while it's undeclared inquasar
and the starter-kit, this is problematic as it relies on hoisting to place the correctvue
version in an accessible location for all of them and any other dependency that might need access to it. Hoisting is an implementation detail and does not guarantee this to happen.For example when using workspaces one workspace might use
vue@2
while the other usesvue@3
, which one getting hoisted to the root is undefined.To solve this
vue
is changed to be a peer dependency which correctly reflects the intent that one workspace (quasar project) uses one version ofvue