yarn
yarn copied to clipboard
`yarn add` with package already installed removes the package
when using workspaces
Bug description
yarn add with package already installed removes the package
It happens when using the latest tag
Command
yarn add recharts@latest
yarn add recharts@latest
then i won't find recharts in node_modules
Steps to Reproduce
- create some workspaces packages (not sure if happens without workspaces)
- install 2 times a package
- try import the package or check the root node_modules
Environment
- Node Version:
12.13 - Yarn v1 Version:
1.22.4 - OS and version: Mac Catalina
I believe it also happens without the @latest tag. Also, I've noticed it happens for dependencies with ^ or ~ standing before the version number in package.json. For packages with a fixed version number, the problem does not occur.