yalc
yalc copied to clipboard
package.json publishConfig is not applied
It would be awesome if at least the main and module values could be overwritten based on the publishConfig:
https://yarnpkg.com/configuration/manifest/#publishConfig
https://classic.yarnpkg.com/en/docs/package-json#toc-publishconfig
https://docs.npmjs.com/cli/v6/configuring-npm/package-json#publishconfig
The yarn v2 implementation seems to be stricter in what config values can be overwritten.
I totally agree. I got everything working with yalc but this is a blocker for me 😦
How should publishConfig be applied?
The values in publishConfig should overwrite the relevant top-level values in the base package.json. Here's the documentation for how pnpm does it: https://pnpm.io/package_json#publishconfig
(Sorry for not replying earlier, but @corbt got it).
Circling back around, this is still a blocker for me. It creates a divergence between pnpm publish and yalc publish that breaks the whole concept of the yalc workflow for me.
Maybe you could consider using pnpm package directly, which would guarantee equivalence?
pnpm package
pnpm pack*