The polyfills/__dist folder is missing on 3.22.0 on NPM, so the service fails to start with the error:
No polyfill sources found. Runnpm run buildto build them
I think it's on purpose. You have to npm install && npm run build
It is meant to run npm run build automatically after it is installed. Which version of npm are you using @dcherman ?
@JakeChampion I've got yarn 1.0.2 installed. FWIW, the artifacts uploaded to NPM for 3.21.0 do contain the dist folder, and I don't see a postinstall step that runs npm run build or anything.
Actually, it looks like there's even a step that is intended to build the polyfills prior to releasing them to npm that may not have gotten run for whatever reason:
"prepublish": "npm run build"
I believe prepublish automatically runs on anpm install. Having the same issue with yarn as well.
I just investigated a bit further:
/polyfills/__dist folder. This behaviour did not change since v3.22, so it is not the source of the missing files.prepublish hook, which does run automatically after a npm install (like @gabemeola conjectured above), but apparently does not.I am not sure why the hook runs in 3.21, but not in 3.22.
My workaround with yarn is to use a postinstall script my package.json.
"postinstall": "cd node_modules/polyfill-service && npm run build",
Confirmed that this was fixed up in 3.24.0. Thanks @JakeChampion
Most helpful comment
@JakeChampion I've got yarn 1.0.2 installed. FWIW, the artifacts uploaded to NPM for 3.21.0 do contain the dist folder, and I don't see a
postinstallstep that runsnpm run buildor anything.Actually, it looks like there's even a step that is intended to build the polyfills prior to releasing them to npm that may not have gotten run for whatever reason:
"prepublish": "npm run build"