Docs: https://github.com/changesets/changesets
We rely on the (seemingly undocumented) changesets feature to publish a package at a subdirectory introduced in this PR: changesets/changesets#428
To leverage this, we need the following in the relevant package.json:
"scripts": {
// ...
// Optional:
"postpack": "echo 'FORBIDDEN' && exit 1"
},
"publishConfig": {
"access": "public",
"directory": "release"
}
We use this, for example, in grafast so that we can release a webpacked version of the code to clear development code and minimise require/import overhead.