You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
add "react": "15.0.1" to dependencies inside ./packages/a
add "react": "^15.0.1" to dependencies inside ./packages/b
run $ yarn in the root of the project
What is the expected behavior?
only[email protected] is installed at ./node_modules/react (because b accepts 15.0.1, too) (I'd expect this to be the default behaviour)
Please mention your node.js, yarn and operating system version.
Node v6.9.1
yarn v0.27.5
Mac OS X
Workspaces look great so far! ♥
Question
I'm not certain if resolutions is already implemented. I saw this in several issues, but not in any docs. Given it is implemented, should this issue be workaround by adding this part to ./package.json?:
"resolutions": {
"react": "15.0.1"
}
I don't want to install everything flat (not if some lib wants ^1.0.0 and another lib wants ^2.0.0 from a certain dep), but I do want to install it as flat as possible, if versions fit into a range (like in this case, because 15.0.1 fits into ^15.0.1).
The text was updated successfully, but these errors were encountered:
I think this is not directly workspace related, it is inefficiency of our resolution algorithm.
We need to make it smarter, see this issues for details #3778
Do you want to request a feature or report a bug?
bug?
What is the current behavior?
[email protected]
is installed at./node_modules/react
[email protected]
is installed at./packages/b/node_modules/react
If the current behavior is a bug, please provide the steps to reproduce.
$ git clone [email protected]:pedronauck/yarn-workspaces-example.git
"react": "15.0.1"
todependencies
inside./packages/a
"react": "^15.0.1"
todependencies
inside./packages/b
$ yarn
in the root of the projectWhat is the expected behavior?
[email protected]
is installed at./node_modules/react
(becauseb
accepts15.0.1
, too) (I'd expect this to be the default behaviour)Please mention your node.js, yarn and operating system version.
Workspaces look great so far! ♥
Question
I'm not certain if
resolutions
is already implemented. I saw this in several issues, but not in any docs. Given it is implemented, should this issue be workaround by adding this part to./package.json
?:I don't want to install everything flat (not if some lib wants
^1.0.0
and another lib wants^2.0.0
from a certain dep), but I do want to install it as flat as possible, if versions fit into a range (like in this case, because15.0.1
fits into^15.0.1
).The text was updated successfully, but these errors were encountered: