Closed dpraul closed 3 years ago
Hello!
From Webpack's type definitions we can see that the sourceFilename
is an optional value:
/**
* when asset was created from a source file (potentially transformed), the original filename relative to compilation context
*/
sourceFilename?: string;
Given git-revision-webpack-plugin
generates these assets not from a source file, I would say that the issue in in the Angular plugin.
I'll close this issue, but feel free to re-open if I'm mistaken or if you have new information.
Cheers 👋
Hello! I'm transitioning an application from Angular 11 to 12 and the build fails when utilizing this plugin alongside the
AngularWebpackPlugin
.The following error is raised during compilation:
Here is the line in question in the
AngularWebpackPlugin
: https://github.com/angular/angular-cli/blob/736a5f89deaca85f487b78aec9ff66d4118ceb6a/packages/ngtools/webpack/src/resource_loader.ts#L279-L284The build completes successfully if I rewrite line 280 of the previous source to the following line:
I'm not certain if the check in the
AngularWebpackPlugin
should be adjusted or if extra information needs to be attached to the assets produced from this plugin, but figured I'd start with raising the issue here.