Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(950)

Unified Diff: third_party/closure_compiler/closure_args.gni

Issue 2179033002: Strip comments and whitespace from javascript resources (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix naming of GN variables, and rebase. Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/closure_compiler/compile2.py » ('j') | third_party/closure_compiler/js_minify.py » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/closure_compiler/closure_args.gni
diff --git a/third_party/closure_compiler/closure_args.gni b/third_party/closure_compiler/closure_args.gni
index b1cd18974247bb1e587e661eecd99c629468a76d..182cae96903a210c6e7248fe69c4153cd729fbed 100644
--- a/third_party/closure_compiler/closure_args.gni
+++ b/third_party/closure_compiler/closure_args.gni
@@ -3,8 +3,9 @@
# found in the LICENSE file.
# GYP version: third_party/closure_compiler/closure_args.gypi
-closure_args = [
- "compilation_level=SIMPLE_OPTIMIZATIONS",
+
+# Args for all uses of the closure compiler
+common_closure_args = [
"extra_annotation_name=attribute",
"extra_annotation_name=demo",
@@ -15,6 +16,18 @@ closure_args = [
"extra_annotation_name=status",
"extra_annotation_name=submodule",
+ "language_in=ECMASCRIPT6_STRICT",
+ "language_out=ECMASCRIPT5_STRICT",
+
+ "polymer_pass",
+
+ "source_map_format=V3",
+]
+
+# Additional closure args for performing full checks.
+checking_closure_args = [
+ "compilation_level=SIMPLE_OPTIMIZATIONS",
+
"jscomp_error=accessControls",
"jscomp_error=ambiguousFunctionDecl",
"jscomp_error=checkTypes",
@@ -33,15 +46,11 @@ closure_args = [
"jscomp_error=unknownDefines",
"jscomp_error=uselessCode",
"jscomp_error=visibility",
-
- "language_in=ECMASCRIPT6_STRICT",
- "language_out=ECMASCRIPT5_STRICT",
-
- "polymer_pass",
-
- "source_map_format=V3",
]
+# For compatibility with old uses.
+closure_args = common_closure_args + checking_closure_args
+
default_disabled_closure_args = [
"jscomp_off=duplicate",
"jscomp_off=misplacedTypeAnnotation",
« no previous file with comments | « no previous file | third_party/closure_compiler/compile2.py » ('j') | third_party/closure_compiler/js_minify.py » ('J')

Powered by Google App Engine
This is Rietveld 408576698