diff --git a/tensorboard/defs/defs.bzl b/tensorboard/defs/defs.bzl index 75bd2f1a15f..f8c68e6f2ee 100644 --- a/tensorboard/defs/defs.bzl +++ b/tensorboard/defs/defs.bzl @@ -77,6 +77,10 @@ def tf_js_binary( terser_minified( name = internal_result_name, src = internal_rollup_name, + # Notes about the terser config: + # compress.passes - this is set to '1' to workaround issue with + # terser and threejs. In practice it (surprisingly) generates + # smaller results than when it was previously set to '3'. config_file = "//tensorboard/defs:terser_config.json", visibility = ["//visibility:private"], sourcemap = False, diff --git a/tensorboard/defs/terser_config.json b/tensorboard/defs/terser_config.json index 78914c24e37..7c2d5c7bfbb 100644 --- a/tensorboard/defs/terser_config.json +++ b/tensorboard/defs/terser_config.json @@ -4,7 +4,7 @@ }, "compress": { "keep_fnames": true, - "passes": 3, + "passes": 1, "pure_getters": true, "reduce_funcs": true, "reduce_vars": true,