All Questions
Tagged with yarn-v4 or yarnpkg-v4
26 questions
1
vote
1
answer
95
views
How to enforce Node version in Yarn v4?
I have this in package.json:
"engines": {
"node": ">=18.20.5"
},
But when trying to install (yarn install) using Node version 18.20.3 did not throw any errors,...
0
votes
0
answers
110
views
Vercel and yarn v4 - using .env vars in yarnrc file
I’m using yarn v4 workspaces and need to be able to add an NPM token to access a private package.
Locally this works fine as I can either define a .env.yarn file or add it to my .env file and use the ...
0
votes
1
answer
343
views
Yarn 4+ uses PnP instead of node-modules on Expo eas build
As the title says.
I have an Expo application running on SDK 52 and built on React-native. Im using Yarn 4.7 and have set this in my package.json:
"packageManager": "[email protected]"
...
1
vote
2
answers
2k
views
tsconfig.json extends from base not found
I'm trying to setup a new project where I want to use typescript (and eslint, prettier and jest but that's less important). I'm following this tutorial: https://www.youtube.com/watch?v=-sswKgneCVI
...
0
votes
1
answer
1k
views
Upgrading multistage docker from yarn 1 to yarn modern
I have a Dockerfile written using old yarn
FROM node:20-alpine AS dependencies
WORKDIR /app
COPY package.json ./
COPY yarn.lock ./
RUN yarn install --production --frozen-lockfile && yarn ...
0
votes
1
answer
180
views
Github Actions & Yarn: Invalid resolution json5@npm:^2.2.2 → npm:1.0.2
It works on my local, but yarn install fails on github actions.
I have setup Node and yarn version same as my project
- name: Checkout code
uses: actions/checkout@v2
- name: Set ...
0
votes
1
answer
213
views
Yarn not enforcing Node version specified in package.json
I have this situation in which my application will not run if the Node version is below v20.
In package.json I have:
"engines": {
"node": "^20.10.0",
"yarn&...
3
votes
2
answers
4k
views
How do I upgrade legacy yarn(1.22.x) to yarn 4.x globally?
As far as I know, npm install -g yarn or sudo apt install yarn installs the legacy yarn version which is 1.22.x. If you want to migrate to yarn 4.x for a specific project, it is possible using yarn ...
1
vote
1
answer
81
views
Replacing the version of a dependency at any depth
I clone this repo, and add overrides field to airflow/www/package.json to forcefully specify version of glob at any depth:
{
"name": "airflow-www",
...
"resolutions"...
2
votes
1
answer
347
views
How can I use yarn portal dependencies from different folder levels in my monorepo?
I'm trying to use portals in my monorepo with Yarn 4.1.0 and it can't resolve a common dependency when it is referred to from parent directories which are nested differently in the monorepo, even ...
10
votes
3
answers
17k
views
Migrate my yarn project from [email protected] to [email protected]
My project is using [email protected] and node 16.x.x i want to update my node version to node 20 and i new that node 20 works with [email protected].
When i went to yarn page migration https://yarnpkg.com/...
11
votes
2
answers
10k
views
Why does corepack try to install yarn v1.22 by default when v4.11 is the latest?
I can see corepack about to download yarn v1.22 when I run the yarn command:
user@laptop:~/empty-directory$ yarn
Corepack is about to download https://registry.yarnpkg.com/yarn/-/yarn-1.22.22.tgz.
Do ...
2
votes
1
answer
792
views
What are alternatives to --no-commit-hooks and --no-git-tag-version in yarn v4
I'm migrating from the classic yarn to version 4 and encountered an issue with my version bump CI job since the --no-commit-hooks and --no-git-tag-version flags are not there anymore with the modern ...