Skip to content

Commit 5eb002b

Browse files
authored
docs: declare node-linker when using Yarn 3 (#7113)
Because of yarn 3 use PnP by default, but electron-builder still need node-modules. So add configuration in the `.yarnrc.yaml`: ``` nodeLinker: "node-modules" ``` will declare to use node-modules instead of PnP.
1 parent 0c52841 commit 5eb002b

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

README.md

+8
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,14 @@ public-hoist-pattern=*
9292
shamefully-hoist=true
9393
```
9494

95+
### Note for Yarn 3
96+
97+
Yarn 3 use PnP by default, but electron-builder still need node-modules(ref: [yarnpkg/berry#4804](https://github.com/yarnpkg/berry/issues/4804#issuecomment-1234407305)). Add configuration in the `.yarnrc.yaml` as follows:
98+
```
99+
nodeLinker: "node-modules"
100+
```
101+
will declare to use node-modules instead of PnP.
102+
95103
## Quick Setup Guide
96104

97105
[electron-webpack-quick-start](https://github.com/electron-userland/electron-webpack-quick-start) is a recommended way to create a new Electron application. See [Boilerplates](https://www.electron.build/#boilerplates).

0 commit comments

Comments
 (0)