Closed anvlkv closed 4 years ago
Hi @anvlkv
This functionality currently doesn't exist, but we would accept pull requests for you to add these attributes onto the relevant tags.
If you are interested in doing so, you would need to replicate similar functionality to what the SRI Plugin has here: https://github.com/waysact/webpack-subresource-integrity/blob/master/index.js#L266-L287
You'll then be able to access the hashes and nonces via the htmlWebpackPlugin
variable like you do for files
above
Description
I'm using the plugin with .cshtml file. My template is like this:
The output I'm getting is like this:
What type of issue is this? (place an
x
in one of the[ ]
)Requirements (place an
x
in each of the[ ]
)Question OR Enhancement
In order for webpack-html-plugin to work with these files I'm using this in my .cshtml template
It seems I need something similar for the csp-html-webpack-plugin. Is there a better way to do it, that is not documented?