-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support Yarn PnP #77
Comments
Indeed. FYI the side-effect will be removed soon. In the meantime use pnpm (recommended) or npm instead. |
@ezracelli @dvteixeira24 is the fix (workaround) also compatible with npm and pnpm? |
@brillout also pnpm can use PnP with Can I help with a PR to remove the side-effects? If yes, there are some guidelines? |
I got sidetracked by Vike's success. It's still very much on the radar, but it requires some complex restructuring (breaking down the Telefunc package into multiple packages
That'd be great. Although, for this one, it's better I do it. Would you be up to contribute on something else? |
Actually, we can give it a try. Let's see how it goes 👀 But let's be open to finish the PR later if it get's too complex.
Yes, have a look at Telefunc's Vite plugin, you'll see the code that writes to
See vikejs/vike#1349, most notably:
Looking forward to it! |
Since Telefunc will be splitted in multiple packages, it doesn't seem to make sense to start a PR now. Thanks for the recap of the activities, I will take a look at where I can help. |
PnP (a module installation strategy used by Yarn Berry) stores modules in
.zip
files. When a package is imported, the package manager creates an isolated, read-only virtual filesystem. More info: https://yarnpkg.com/features/pnptelefunc/vite#plugin
has a side-effect that attempts to write to one oftelefunc
's own files. Due to the read-only nature of the virtual filesystem created by PnP, this write fails.telefunc/telefunc/node/vite/index.ts
Lines 20 to 21 in 1327645
telefunc/telefunc/node/vite/importGlob/toggle.ts
Lines 21 to 22 in 1327645
Workaround
I patched the module manually.
The text was updated successfully, but these errors were encountered: