This repository was archived by the owner on Jan 26, 2019. It is now read-only.
File tree 2 files changed +6
-0
lines changed
2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ var HtmlWebpackPlugin = require('html-webpack-plugin');
15
15
var ExtractTextPlugin = require ( 'extract-text-webpack-plugin' ) ;
16
16
var ManifestPlugin = require ( 'webpack-manifest-plugin' ) ;
17
17
var InterpolateHtmlPlugin = require ( 'react-dev-utils/InterpolateHtmlPlugin' ) ;
18
+ var SubresourceIntegrityPlugin = require ( 'webpack-subresource-integrity' ) ;
18
19
var url = require ( 'url' ) ;
19
20
var paths = require ( './paths' ) ;
20
21
var getClientEnvironment = require ( './env' ) ;
@@ -259,6 +260,10 @@ module.exports = {
259
260
// having to parse `index.html`.
260
261
new ManifestPlugin ( {
261
262
fileName : 'asset-manifest.json'
263
+ } ) ,
264
+ // Generate and inject subresources hashes in the final `index.html`.
265
+ new SubresourceIntegrityPlugin ( {
266
+ hashFuncNames : [ 'sha256' , 'sha384' ]
262
267
} )
263
268
] ,
264
269
// Some libraries import Node modules but don't use them in the browser.
Original file line number Diff line number Diff line change 64
64
"webpack" : " 1.13.2" ,
65
65
"webpack-dev-server" : " 1.16.2" ,
66
66
"webpack-manifest-plugin" : " 1.1.0" ,
67
+ "webpack-subresource-integrity" : " 0.7.0" ,
67
68
"whatwg-fetch" : " 1.0.0"
68
69
},
69
70
"devDependencies" : {
You can’t perform that action at this time.
0 commit comments