Use the Node executable provided by the workspace’s pnpm installation #10390
Unanswered
guillaume-mueller
asked this question in
Q&A
Replies: 1 comment
-
|
{
"name": "vitest-pnpm-11",
"devEngines": {
"runtime": {
"name": "node",
"version": "24.4.0",
"onFail": "download"
}
},
"scripts": {
"test": "vitest"
},
"dependencies": {
"vitest": "^4"
}
}import { test } from "vitest";
test("version", () => {
console.log(process.versions.node);
});$ pnpm install
Packages: +1 -1
+-
Downloading node@runtime:24.4.0: 48.85 MB/48.85 MB, done
$ pnpm test
stdout | example.test.ts > version
24.4.0
✓ example.test.ts (1 test) 1ms
✓ version 1ms "devEngines": {
"runtime": {
"name": "node",
- "version": "24.4.0",
+ "version": "22.1.0",
"onFail": "download"
}
},$ pnpm i
Packages: +1 -1
+-
Progress: resolved 76, reused 52, downloaded 0, added 0, done
devDependencies:
- node 24.4.0
+ node 22.1.0
$ pnpm test
stdout | example.test.ts > version
22.1.0
✓ example.test.ts (1 test) 1ms
✓ version 1ms
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
How to use the Node executable selected in
package.jsonthe following way that pnpm v11 handles ?Beta Was this translation helpful? Give feedback.
All reactions