Skip to content
GitLab
Explore
Projects
Groups
Snippets
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Meta
create-react-app
Commits
11cd8138
Commit
11cd8138
authored
8 years ago
by
Vincenzo Chianese
Committed by
Dan Abramov
8 years ago
Browse files
Options
Download
Email Patches
Plain Diff
Add Subresource Integrity support (#1176)
* Add Subresource Integrity support * Pin dependency
parent
80765677
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
packages/react-scripts/config/webpack.config.prod.js
+5
-0
packages/react-scripts/config/webpack.config.prod.js
packages/react-scripts/package.json
+1
-0
packages/react-scripts/package.json
with
6 additions
and
0 deletions
+6
-0
packages/react-scripts/config/webpack.config.prod.js
+
5
-
0
View file @
11cd8138
...
...
@@ -15,6 +15,7 @@ var HtmlWebpackPlugin = require('html-webpack-plugin');
var
ExtractTextPlugin
=
require
(
'
extract-text-webpack-plugin
'
);
var
ManifestPlugin
=
require
(
'
webpack-manifest-plugin
'
);
var
InterpolateHtmlPlugin
=
require
(
'
react-dev-utils/InterpolateHtmlPlugin
'
);
var
SubresourceIntegrityPlugin
=
require
(
'
webpack-subresource-integrity
'
);
var
url
=
require
(
'
url
'
);
var
paths
=
require
(
'
./paths
'
);
var
getClientEnvironment
=
require
(
'
./env
'
);
...
...
@@ -259,6 +260,10 @@ module.exports = {
// having to parse `index.html`.
new
ManifestPlugin
({
fileName
:
'
asset-manifest.json
'
}),
// Generate and inject subresources hashes in the final `index.html`.
new
SubresourceIntegrityPlugin
({
hashFuncNames
:
[
'
sha256
'
,
'
sha384
'
]
})
],
// Some libraries import Node modules but don't use them in the browser.
...
...
This diff is collapsed.
Click to expand it.
packages/react-scripts/package.json
+
1
-
0
View file @
11cd8138
...
...
@@ -64,6 +64,7 @@
"webpack"
:
"1.13.2"
,
"webpack-dev-server"
:
"1.16.2"
,
"webpack-manifest-plugin"
:
"1.1.0"
,
"webpack-subresource-integrity"
:
"0.7.0"
,
"whatwg-fetch"
:
"1.0.0"
},
"devDependencies"
:
{
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Snippets