Skip to content
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

psc: "psa" does not work with Yarn PnP #141

Open
elliotdavies opened this issue Feb 26, 2020 · 0 comments
Open

psc: "psa" does not work with Yarn PnP #141

elliotdavies opened this issue Feb 26, 2020 · 0 comments

Comments

@elliotdavies
Copy link

In the new version of Yarn the module resolution has changed by default to a bespoke system called PnP. When using PnP it's no longer possible to implicitly rely on dependencies (i.e. without specifying them in package.json).

The upshot is that with PnP enabled, setting psc: "psa" in this loader doesn't work: it throws the spawn psa NOENT error that you usually see if purescript-psa isn't installed. I think this is because, even if the consuming project installs purescript-psa, purs-loader is still implicitly depending on that module existing.

A possible resolution (I'd need to test it) would be to list purescript-psa as either a dependency or peer dependency of this package.

(Side note: I assume the same issue would occur with psa: "purs", and I assume the same fix - adding purescript as a peer dependency - would sort it out.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant