File tree Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Expand file tree Collapse file tree 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');
1515var  ExtractTextPlugin  =  require ( 'extract-text-webpack-plugin' ) ; 
1616var  ManifestPlugin  =  require ( 'webpack-manifest-plugin' ) ; 
1717var  InterpolateHtmlPlugin  =  require ( 'react-dev-utils/InterpolateHtmlPlugin' ) ; 
18+ var  SubresourceIntegrityPlugin  =  require ( 'webpack-subresource-integrity' ) ; 
1819var  url  =  require ( 'url' ) ; 
1920var  paths  =  require ( './paths' ) ; 
2021var  getClientEnvironment  =  require ( './env' ) ; 
@@ -259,6 +260,10 @@ module.exports = {
259260    // having to parse `index.html`. 
260261    new  ManifestPlugin ( { 
261262      fileName : 'asset-manifest.json' 
263+     } ) , 
264+     // Generate and inject subresources hashes in the final `index.html`. 
265+     new  SubresourceIntegrityPlugin ( { 
266+       hashFuncNames : [ 'sha256' ,  'sha384' ] 
262267    } ) 
263268  ] , 
264269  // Some libraries import Node modules but don't use them in the browser. 
Original file line number Diff line number Diff line change 6464    "webpack" : " 1.13.2" 
6565    "webpack-dev-server" : " 1.16.2" 
6666    "webpack-manifest-plugin" : " 1.1.0" 
67+     "webpack-subresource-integrity" : " 0.7.0" 
6768    "whatwg-fetch" : " 1.0.0" 
6869  },
6970  "devDependencies" : {
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments