added a missing commonjs()

This commit is contained in:
Dominic Gannaway
2017-04-04 15:54:21 +01:00
parent c31950084c
commit 845052292a
+5 -3
View File
@@ -271,9 +271,7 @@ function getCommonJsConfig(bundleType) {
case NODE_PROD:
return {};
case RN:
return {
ignore: ignoreReactNativeModules(),
};
return {};
case FB_DEV:
case FB_PROD:
// Modules we don't want to inline in the bundle.
@@ -481,6 +479,10 @@ function getPlugins(entry, babelOpts, paths, filename, bundleType, isRenderer, m
// needs to happen after strip env
commonjs(getCommonJsConfig(bundleType))
);
} else {
plugins.push(
commonjs(getCommonJsConfig(bundleType))
);
}
// this needs to come last or it doesn't report sizes correctly
plugins.push(