Support SRI on webpack-plugin
See original GitHub issue🚀 Feature Proposal
Putting an integrity string for SRI into loadable-stats.json
when building bundles.
Motivation
To embed integrity
attribute for each script tag when running SSR application with loadable components, I need to read the file and compute the integrity value on runtime.
Instead of that, I would like to compute the integrity value at the building phase to reduce overhead on runtime.
Example
Putting integrity value into loadable-stats.json
{
"name": "xxx-e63d1f6f130186a006da.js",
"size": 782370,
"integrity": "sha384-oqVuAfXRKap7fdgcCY5uykM6+R9GqQ8K/uxy9rx7HNQlGYl1kPzQho1wx4JwY8wC",
"chunks": [],
"chunkNames": [],
"emitted": false
},
Then it could be great if we can access the value on attrFn for getScriptTags
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:7 (3 by maintainers)
Top Results From Across the Web
Support SRI on webpack-plugin · Issue #344 - GitHub
I am not sure if webpack has a plan. Currently, I only know this plugin to generate integrity. Do you think if loadable...
Read more >sri-stats-webpack-plugin - npm
Subresource integrity hash generator plugin for webpack.. Latest version: 0.7.3, last published: 6 years ago.
Read more >Webpack-subresource-integrity - npm.io
Webpack plugin for enabling Subresource Integrity. Subresource Integrity (SRI) is a security feature that enables browsers to verify that files they fetch (for ......
Read more >Top 5 webpack-subresource-integrity Code Examples - Snyk
To help you get started, we've selected a few webpack-subresource-integrity examples, based on popular ways it is used in public projects.
Read more >Webpack for SRI rules - Stack Overflow
It hasn't been updated in a few years. If I have a webpack.config.js with plugins: plugins: [ new MiniCssExtractPlugin({ filename: 'css/[name].[ ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I agree with loading the plugin as optional for the first step since integrity seems not so high demand. @neoziro
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.