🚮 Remove closure compiler logic from build-system.#37296
🚮 Remove closure compiler logic from build-system.#37296samouri merged 3 commits intoampproject:mainfrom
Conversation
|
@rcebulko: requesting a review of just the |
| if (minify) { | ||
| log('Minifying multi-pass JS with', cyan('closure-compiler') + '...'); | ||
| } else { | ||
| log('Compiling JS with', cyan('esbuild'), 'and', cyan('babel') + '...'); | ||
| } |
There was a problem hiding this comment.
I think the distinction between minified and non-minified ("compiled", for lack of a better word) ought to remain in the logs. Perhaps change the first word of the sentence to minify ? 'Minifying' : 'Compiling'?
There was a problem hiding this comment.
Is there a distinction between the two with esbuild?
There was a problem hiding this comment.
Sure. I'll put that distinction back in via Compiling minified vs. Compiling unminified, which I think reads clearer.
WDYT of removing the details around esbuild/babel? I think those might be too much detail for this log (why are we excluding the other dozen tools...where do we draw the line..)
There was a problem hiding this comment.
Sure. I'll put that distinction back in via
Compiling minifiedvs.Compiling unminified, which I think reads clearer.
SGTM. 👍
WDYT of removing the details around esbuild/babel? I think those might be too much detail for this log (why are we excluding the other dozen tools...where do we draw the line..)
Fair point. The logging was originally added back when there was a substantial difference between minified (only closure) and unminified (only babel). It's less accurate / useful today given all the recent tooling changes.
build-system/tasks/check-types.js
Outdated
| @@ -6,7 +6,6 @@ const { | |||
| const { | |||
| displayLifecycleDebugging, | |||
There was a problem hiding this comment.
Does displayLifecycleDebugging do anything here?
| // Prepare build environment | ||
| process.env.NODE_ENV = 'production'; | ||
| cleanupBuildDir(); | ||
| typecheckNewServer(); |
There was a problem hiding this comment.
AFAICT the debug flag no longer has meaning in this file
There was a problem hiding this comment.
Should I remove? I don't know what debug/displayLifecycleDebugging are for.
There was a problem hiding this comment.
A quick inspection suggestions displayLifecycleDebugging should only matter if the debug method in that same file is called, and I don't see where it would be called here, but it's possible somewhere in the dependency chain it does get called. Not certain without testing it out
There was a problem hiding this comment.
displayLifecycleDebugging was added in #27700 as a way to print the output at various stages of compilation: babel, closure, more babel, etc. It's triggered by the --debug flag, and was previously used by dist and check-types (both of which used closure).
It's probably far less useful without closure and the pre- and post- babel steps. Okay to remove IMO. Might be worth checking in with someone like @jridgewell to make sure.
…nce-attr-to-hero-img * 'main' of github.com:ampproject/amphtml: (525 commits) mathml storybook: supply missing component definition. (#37326) storybook: Iframe --> BentoIframe (#37327) 🖍 [Story system layer] New ad badge (#37311) 🐛 [amp story] Replay/next page button bug fix (#37316) 🚀 [Story performance] Remove affiliate links (#37280) Compiler: Add amp-carousel-0.1 to the builder map (#37308) ⏪ [Story system layer] Audio icon disappears when story has background audio (#37314) 🚀 [Story performance] Remove story access (#37281) Fix remapping esbuild output on Windows (#37312) 🐛 adds in correct weight for amp-story-product-tag text (#37188) typechecking carousel: remove shame files (#37213) Use remapping to remap minified sourcemap into source code (#37238) SwG Release 0.1.22.199 (#37310) 🐛 Adds microsoft-edge protocol (#34168) Sync for validator cpp engine and cpp htmlparser (#37292) ✨ amp-story-shopping Updated currency with product price and correct Localized currency (#37249) ✨[Smartadserver ad extension] Implement support for Fast Fetch (#36991) Remove client-side-experiments-config.json from this repo (#37304) 🚮 Remove closure compiler logic from build-system. (#37296) 🌐 Added RTL ordering i18n for amp story shopping tag (#37252) ...
summary
Deletes a files directly related to closure compilation from
build-system.Future related changes:
validatortask, s.t. we can remove the dep from package.json