closure-compiler
closure-compiler copied to clipboard
import/export directives ignored when not at the start of line
When debugging problems with unresolved import paths, it turned out that parsing import directives is triggered only when the directive actually starts the line:
JsFileRegexParser:347 (in version 20220601)
if (line.startsWith("import") || line.startsWith("export")) {
If you put whitespace before the import directive, it is just ignored.
Not sure if this is correct and/or intentional, in any case it is rather unexpected.