aboutsummaryrefslogtreecommitdiffstats
path: root/packages/instant/webpack.config.js
diff options
context:
space:
mode:
authorSteve Klebanoff <steve@0xproject.com>2018-12-04 08:52:06 +0800
committerGitHub <noreply@github.com>2018-12-04 08:52:06 +0800
commit703cea6173f72ceb6969bc17bda0735b86477522 (patch)
treef73fb94c3de9e2718bcec5f5d0e0c736c1d11b28 /packages/instant/webpack.config.js
parent2601d16efbb1e85eadca459e5dc64e78099e738a (diff)
parent1107b84949ea74467393edc1496c153f5ce7f64d (diff)
downloaddexon-sol-tools-703cea6173f72ceb6969bc17bda0735b86477522.tar
dexon-sol-tools-703cea6173f72ceb6969bc17bda0735b86477522.tar.gz
dexon-sol-tools-703cea6173f72ceb6969bc17bda0735b86477522.tar.bz2
dexon-sol-tools-703cea6173f72ceb6969bc17bda0735b86477522.tar.lz
dexon-sol-tools-703cea6173f72ceb6969bc17bda0735b86477522.tar.xz
dexon-sol-tools-703cea6173f72ceb6969bc17bda0735b86477522.tar.zst
dexon-sol-tools-703cea6173f72ceb6969bc17bda0735b86477522.zip
Merge pull request #1370 from 0xProject/feature/instant/explicitly-enable-heap-dev
[instant] Must explicitly specify when want to send to heap when developing
Diffstat (limited to 'packages/instant/webpack.config.js')
-rw-r--r--packages/instant/webpack.config.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/packages/instant/webpack.config.js b/packages/instant/webpack.config.js
index a1db01db9..e74cf36d9 100644
--- a/packages/instant/webpack.config.js
+++ b/packages/instant/webpack.config.js
@@ -71,6 +71,7 @@ const generateConfig = (dischargeTarget, heapConfigOptions, rollbarConfigOptions
`Must define heap analytics id in ENV var ${heapAnalyticsIdEnvName} when building for ${dischargeTarget}`,
);
}
+ const heapEnabled = heapAnalyticsId && (nodeEnv !== 'development' || process.env.INSTANT_HEAP_FORCE_DEVELOPMENT);
const rollbarTokens = getRollbarTokens(dischargeTarget, rollbarConfigOptions.rollbarRequired);
const rollbarEnabled =
@@ -92,6 +93,7 @@ const generateConfig = (dischargeTarget, heapConfigOptions, rollbarConfigOptions
GIT_SHA: JSON.stringify(GIT_SHA),
NPM_PACKAGE_VERSION: JSON.stringify(process.env.npm_package_version),
ROLLBAR_ENABLED: rollbarEnabled,
+ HEAP_ENABLED: heapEnabled
};
if (dischargeTarget) {
envVars.INSTANT_DISCHARGE_TARGET = JSON.stringify(dischargeTarget);