-
Notifications
You must be signed in to change notification settings - Fork 11.9k
Closed as not planned
Labels
needs: more infoReporter must clarify the issueReporter must clarify the issue
Description
Command
build
Description
Currently, configuration allows for setting subresourceIntegrity
to true
and this adds a sha384 hash to the html output's script tags.
However, sha384 is not supported in all platforms and/or frontend developers cannot control the deployment servers. (eg: AWS S3 doesn't allow for sha384 with its checksum-algorithm flag)
Request is to allow overriding of the default sha384 that is set here:
angular-cli/packages/angular_devkit/build_angular/src/tools/webpack/configs/common.ts
Line 254 in 20411f6
if (subresourceIntegrity) { |
Describe the solution you'd like
Two options:
- given that custom webpack configurations are already alowed and plugins added there are already expected to override the defaults, allow the existence of
plugins: [
new SubresourceIntegrityPlugin({
enabled: true,
hashFuncNames: ['sha256'],
}),
to override the hardcodedd configuration.
- Add additional configuration parameter for overriding the hashFuncNames setting like:
..., "subresourceIntegrity": true, "hashFuncNames": ["sha256", "sha512"], ...
### Describe alternatives you've considered
I have tried adding the plugin in my custom webpack.config.js file.
I've also tried to completely rework the settings in Angular to allow for a fully customizable index file...but I honestly just lack the skill to get that to work.
Metadata
Metadata
Assignees
Labels
needs: more infoReporter must clarify the issueReporter must clarify the issue