Conversation
- Refactored `WebpackManifestLoader` and `AbstractWebpackLoader` to handle array-based manifest entries with custom configuration. - Updated `AssetFactory` to support type-safe configurations combining `AssetConfig` and `AssetExtensionConfig`. - Introduced new test cases for custom manifest configurations. - Enhanced documentation to detail alternative manifest formats and examples.
widoz
commented
Nov 2, 2025
Chrico
reviewed
Nov 10, 2025
Chrico
reviewed
Nov 10, 2025
Chrico
reviewed
Nov 10, 2025
Chrico
reviewed
Nov 10, 2025
…ackManifestLoader` for improved asset handling - Renamed `sanitizeHandle` to `normalizeHandle` for clarity. - Adjusted `handleAsArray` to streamline configuration processing and include exception handling. - Updated `AssetFactory` usage to a static call for better readability.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #66 +/- ##
============================================
+ Coverage 86.79% 87.22% +0.43%
- Complexity 315 334 +19
============================================
Files 27 27
Lines 901 955 +54
============================================
+ Hits 782 833 +51
- Misses 119 122 +3
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Member
Author
|
Hi @Chrico |
Chrico
reviewed
Nov 11, 2025
Chrico
reviewed
Nov 11, 2025
…consistency with static-based asset resolution
…for consistency with instance-based asset resolution - Updated `AbstractWebpackLoader` and `WebpackManifestLoader` to use the instance method `resolveClassByExtension`.
Chrico
approved these changes
Nov 11, 2025
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.
Please check if the PR fulfills these requirements
What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)
Allow to have a predefined configuration for each asset created and registered through the WebPack Manifest Loader
What is the current behavior? (You can also link to an open issue here)
When we want to use the WebPack Manifest Loader, we luckly have to refine the asset configuration in some manner, e.g. to set multiple locations, to set a version, to disable the enqueue and so on...
What is the new behavior (if this is a feature change)?
We can take advantage of the Manifest Plugin
generatecallback, a callback giving us the possibility to customize the output generated by the WebPack plugin. Thanks to that, we can generate a manifest where the handle value isn't just a file path, but an object holding the configuration later on we'll serve to theAssetFactory.This permit us to avoid to manipulate the asset before the registration happen, delegating to the
WebpackManifestLoaderthis task.Does this PR introduce a breaking change? (What changes might users need to make in their application due to this PR?)
No, the implementation is still supporting the previous manifest structure, but add support for the new object configuration.
Other information
WebpackManifestLoaderandAbstractWebpackLoaderto handle array-based manifest entries with custom configuration.AssetFactoryto support type-safe configurations combiningAssetConfigandAssetExtensionConfig.