fix: leave default PWA icons out of a bundle with a custom icon path - #25489
Open
mcollovati wants to merge 2 commits into
Open
fix: leave default PWA icons out of a bundle with a custom icon path#25489mcollovati wants to merge 2 commits into
mcollovati wants to merge 2 commits into
Conversation
The default production bundle ships PWA icons scaled from icons/icon.png. When an application points @pwa(iconPath) somewhere else, TaskGeneratePWAIcons writes the scaled icons under the configured path instead, so the ones unpacked from the bundle are never served and only add around 700 kB of unused images to the production artifact. Skip them while copying the bundle in that case. Also report which image the icons are generated from at INFO level when the icon path is customized, so that the source of the shipped icons is visible without enabling debug logging. Fixes #21411
Logger.atLevel is SLF4J 2 only. Maven exports its own slf4j-api 1.7 from the core class realm into plugin class loaders, so build-frontend died with a NoSuchMethodError as soon as an application enabled PWA. Pick the level with a branch instead.
|
Contributor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



The default production bundle ships PWA icons scaled from icons/icon.png. When an application points
@PWA(iconPath)somewhere else, TaskGeneratePWAIcons writes the scaled icons under the configured path instead, so the ones unpacked from the bundle are never served and only add around 700 kB of unused images to the production artifact. Skip them while copying the bundle in that case.Also report which image the icons are generated from at INFO level when the icon path is customized, so that the source of the shipped icons is visible without enabling debug logging.
Fixes #21411