-
Notifications
You must be signed in to change notification settings - Fork 823
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adds non-fatal warnings to the build tools #1325
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is ok, but I'm pretty gutted that we aren't logging warnings when the user uses workbox-build.
I.e. if I use the CLI and webpack - I get warnings logged to the console but if I use Gulp, I have to wire this up :(
* }; | ||
* | ||
* @callback ManifestTransform | ||
* @param {Array<ManifestEntry>} manifestEntries The full array of entries, | ||
* prior to the current transformation. | ||
* @return {Array<ManifestEntry>} The array of entries with the transformation | ||
* applied. | ||
* @return {{manifest: Array<ManifestEntry>, warnings: Array<String>}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make the warnings optional to return.
}); | ||
|
||
return entry; | ||
}); | ||
return {manifest, warnings: []}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Exclude the warnings here.
return entry; | ||
}); | ||
|
||
return {manifest, warnings: []}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Exclude the warnings here.
I'm happy that we're returning the E.g., we handle errors from modules in our own first-party |
PR-Bot Size PluginChanged File Sizes
New FilesNo new files have been added. All File SizesView Table
Workbox Aggregate Size Plugin☠️ WARNING ☠️We are using 155% of our max size budget. Total Size: 22.7KB Gzipped: 9.1KB |
@jeffposnick thanks so much! |
R: @addyosmani @gauntface
Fixes #1315, fixes #1176
This adds in support for non-fatal warnings in
workbox-build
, as well as reporting those errors back to the developers viaworkbox-cli
anworkbox-webpack-plugin
.Two classes of problems are treated as warnings now:
maximumFileSizeToCacheInBytes