Updated rollup to 0.60.1, made code changes to support it (#151)

This commit is contained in:
Mateusz Burzyński 2018-06-21 15:00:45 +02:00 committed by Leah
parent 8286def15f
commit bf2d068dc6
3 changed files with 6 additions and 5 deletions

1
.npmrc Normal file
View File

@ -0,0 +1 @@
package-lock=false

View File

@ -50,7 +50,7 @@
"gzip-size": "^4.1.0",
"pretty-bytes": "^5.1.0",
"regenerator-runtime": "^0.11.1",
"rollup": "0.59.3",
"rollup": "^0.60.1",
"rollup-plugin-buble": "^0.19.2",
"rollup-plugin-bundle-size": "^1.0.1",
"rollup-plugin-commonjs": "^9.0.0",

View File

@ -189,8 +189,8 @@ export default async function microbundle(options) {
inputOptions.cache = cache;
let bundle = await rollup(inputOptions);
cache = bundle;
await bundle.write(outputOptions);
return await getSizeInfo(bundle._code, outputOptions.file);
const { code } = await bundle.write(outputOptions);
return await getSizeInfo(code, outputOptions.file);
}),
);
@ -415,8 +415,8 @@ function createConfig(options, entry, format, writeMeta) {
},
],
{
ongenerate({ bundle }, { code }) {
config._code = bundle._code = code;
ongenerate(outputOptions, { code }) {
config._code = code;
},
},
shebangPlugin(),