You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to convert our code from goog.provide modules to ES6 modules, but I've run into a difference in behavior that I didn't expect. When running in LOOSE dependency mode, the compiler includes all ES6 modules regardless of whether they're a dependency of the entry point. When I used goog.provide, these files were excluded from compilation. Based on https://github.com/google/closure-compiler/wiki/Managing-Dependencies#working-with-files-that-do-not-specify-dependencies, I'd expect the ES6 modules to work the way goog.provide modules do.
Running in STRICT mode eliminates files that aren't imported by the entry point, but it also eliminates non-module files (as expected). We have some non-module legacy files that we include in some of our builds, so I don't want to switch to STRICT if I can avoid it.
Can you make ES6 modules work like goog.provide, or at least clarify that section of the wiki?
Thanks!
The text was updated successfully, but these errors were encountered:
I'm trying to convert our code from
goog.provide
modules to ES6 modules, but I've run into a difference in behavior that I didn't expect. When running inLOOSE
dependency mode, the compiler includes all ES6 modules regardless of whether they're a dependency of the entry point. When I usedgoog.provide
, these files were excluded from compilation. Based on https://github.com/google/closure-compiler/wiki/Managing-Dependencies#working-with-files-that-do-not-specify-dependencies, I'd expect the ES6 modules to work the waygoog.provide
modules do.Running in
STRICT
mode eliminates files that aren't imported by the entry point, but it also eliminates non-module files (as expected). We have some non-module legacy files that we include in some of our builds, so I don't want to switch toSTRICT
if I can avoid it.Can you make ES6 modules work like
goog.provide
, or at least clarify that section of the wiki?Thanks!
The text was updated successfully, but these errors were encountered: