Use this tag for version specific questions about Yarn version 2.x. Yarn is an open-source JavaScript package manager created by Facebook, Exponent, Google, and Tilde. When using this tag also include the more generic [yarnpkg] tag where possible.
Questions tagged [yarnpkg-v2]
192 questions
1
vote
1 answer
How to Yarn add a specific branch/workspace
I forked react-select to add a couple of features that the current react-select doesn't have. I created a branch and committed it to my forked project. Now, i want to use the forked project.
Ive tried installing the forked react-select repo the…

Hector
- 6,625
- 3
- 16
- 18
1
vote
0 answers
Invalid descriptor with yarn berry Github subdirectory install
I need to install a subdirectory of a remote repository as my node dependency.
According to this issue, it is possible to install subdirectories of GitHub repositories as dependencies with yarn 2.x.x…

Marian Klühspies
- 15,824
- 16
- 93
- 136
1
vote
0 answers
Should we Copy Yarn cache inside a Docker Container?
I read a docker blog post that advises to re-run npm install when building a docker container because node_modules may contain binaries compiled for your host OS, and if it’s different then the container OS, you’ll get errors trying to run your app…

akshat
- 107
- 8
1
vote
0 answers
How to share dependencies in package.json definition using yarn 2?
We are using yarn workspace 2 monorepo project.
Our problem is, that there a 10 miniproject contains (for example):
"devDependencies": {
"typescript": "^4.0.2"
}
Is there any stategy how to define some ROOT parent of package.json and exnted…

vimov32802
- 89
- 2
- 5
1
vote
2 answers
Error upgrading dependencies in yarn.lock file with yarn up in Yarn 2.0
I'm trying to use Yarn 2.0 to upgrade to the latest version of the dependency in my yarn.lock to resolve a dependabot issue. The issue exists with the ini dependency and I tried running command yarn up ini which resulted in the following error:
❯…

AMP_035
- 167
- 1
- 2
- 13
1
vote
4 answers
When you use this plugin you must install `typescript`. error
I am using yarn 2 and react with webpack.
In my package is "typescript": ... defined. Once I start yarn start I am getting an error:
yarn workspace test start
When you use this plugin you must install `typescript`.
What is wrong? How should I fix…

testomalta
- 49
- 1
- 7
1
vote
1 answer
Yarn 2 / Webpack require.resolve "use" array of UseEntry fails to reference loader
I'm trying to upgrade to yarn 2, and am running into a bit of a road block when it comes to "using" array based loaders and resolving properly.
Here is an excerpt from the previous working webpack configuration.
...
{
test:…

tomciopp
- 2,602
- 2
- 31
- 60
1
vote
0 answers
Prisma client schema not found, nextjs app
Disclaimer I am using yarn workspaces, my project is structured like:
- packages
- prisma-client
- web-app (typescript + nextjs)
- service-1 (normal typescript node application)
"service-1" and "web-app" both reference the "prisma-client".…

Bob Ross
- 61
- 1
- 6
1
vote
1 answer
CRA + Yarn 2 + jsconfig.json = Can't run unit tests
I have the following configuration in my jsconfig.json file:
{
"compilerOptions": {
"baseUrl": "./src"
},
"include": ["src"]
}
Which lets me do this:
import { App } from 'components'
import * as actions from 'actions/app.actions'
Instead…

Summer
- 1,175
- 8
- 18
1
vote
0 answers
Overly verbose logging in jest tests
➤ YN0000: [@bb/graph]: console.log
➤ YN0000: [@bb/graph]: info: after all completed
➤ YN0000: [@bb/graph]:
➤ YN0000: [@bb/graph]: at Console.log…

xenoterracide
- 16,274
- 24
- 118
- 243
1
vote
1 answer
How could I change the name of my Yarn Workspace package?
I starting with a yarn workspace that has packages that are already named. I'd like to change the name of one of the packages but have not been able to find the necessary procedure for doing this.
Here's the current structure of the file:
{
…

Tapha
- 1,491
- 3
- 17
- 32
1
vote
0 answers
Yarn UI Logs are unavailable because Application Timeline Service seems unhealthy
Recently, we've installed Cloudera 7.
In a new Yarn UI, I can't see logs of an application.
scrrenshot of yarnUI
Error in the UI:
Logs are unavailable because Application Timeline Service seems unhealthy.
After starting new timelineServer with this…

ipshubin144
- 66
- 6
0
votes
1 answer
Finding all installed versions of an npm package using the yarn API
My goal is to prevent out-of-order deployment of a back-end and an app. All of the software is written in JavaScript. The back-end interface is wrapped up in a API client npm package, which the app imports. The back-end server version and client…

joshuanapoli
- 2,509
- 3
- 25
- 34
0
votes
0 answers
Next.js NODE_OPTIONS is not compatible with yarn v2
Important info:
yarn 2 (berry)
Next.js
I have a following script to run Next.js app (either next dev or next start), and to initialise Datadog APM tracing:
"dev": "NODE_OPTIONS='-r ./utils/tracer.js' next dev"
Since I need to use a dependency in…

M.Wasik
- 1
- 1
0
votes
0 answers
yarn berry declared in dependencies
I created next js project with yarn berry
and tryed to install @yarnpkg/sdks vscode
but the following error has occurred.
as described in the error installed color-convert but showed same error
I searched the Internet, but it didn't come out.

firefox9067
- 31
- 1