You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/guide/guide.md
+28Lines changed: 28 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -145,6 +145,34 @@ Now, create a worker like so:
145
145
```js
146
146
newWorker('./worker.js', { type:'module' })
147
147
```
148
+
## Using Yarn Workspaces
149
+
150
+
If you are using [Yarn workspaces](https://classic.yarnpkg.com/en/docs/workspaces/) you need to set `nodeModulesPath` to include both the package node_modules, and the workspace node_modules.
151
+
152
+
You should also move your eslint config to the workspace root or you'll get lots of weird messages.
153
+
154
+
This is becuase yarn workspaces 'hoists' shared dependencies to the top level and this plugin needs to be able to scan your node_modules to check for native dependencies to externalize.
155
+
156
+
For example, with this directory structure:
157
+
```
158
+
package.json (in workspace root)
159
+
packages/
160
+
app/
161
+
components/
162
+
```
163
+
Inside `packages/app/vue.config.js` add the following line to the plugin config:
0 commit comments