Skip to content

Commit f5aa200

Browse files
backstroke-botdmatchley
authored andcommitted
Update from upstream repo facebookincubator/create-react-app@master (#3)
* `react-error-overlay` has no dependencies now (facebook#3263) * `react-error-overlay` has no dependencies now (it's bundled) * Use babel 6 for now * Add external links to deployment services (facebook#3265) * Add warning when using `react-error-overlay` in production (facebook#3264) * Add a warning when running minified * Add more robust check * Update index.js * Use production React version for bundled overlay (facebook#3267) * Use production React version * We cannot strip our own checks if production * Keep the sourcemap during minify * Prevent devtools pollution * Add some comments * sigh
1 parent 84d8eba commit f5aa200

File tree

1 file changed

+17
-17
lines changed

1 file changed

+17
-17
lines changed

packages/react-error-overlay/webpack.config.iframe.js

+17-17
Original file line numberDiff line numberDiff line change
@@ -4,45 +4,45 @@
44
* This source code is licensed under the MIT license found in the
55
* LICENSE file in the root directory of this source tree.
66
*/
7-
'use strict';
7+
"use strict";
88

9-
const path = require('path');
10-
const webpack = require('webpack');
9+
const path = require("path");
10+
const webpack = require("webpack");
1111

1212
module.exports = {
13-
entry: './src/iframeScript.js',
13+
entry: "./src/iframeScript.js",
1414
output: {
15-
path: path.join(__dirname, './lib'),
16-
filename: 'iframe-bundle.js',
15+
path: path.join(__dirname, "./lib"),
16+
filename: "iframe-bundle.js"
1717
},
1818
module: {
1919
rules: [
2020
{
2121
test: /\.js$/,
22-
include: path.resolve(__dirname, './src'),
23-
use: 'babel-loader',
24-
},
25-
],
22+
include: path.resolve(__dirname, "./src"),
23+
use: "babel-loader"
24+
}
25+
]
2626
},
2727
plugins: [
2828
new webpack.DefinePlugin({
2929
// We set process.env.NODE_ENV to 'production' so that React is built
3030
// in production mode.
31-
'process.env': { NODE_ENV: '"production"' },
31+
"process.env": { NODE_ENV: '"production"' },
3232
// This prevents our bundled React from accidentally hijacking devtools.
33-
__REACT_DEVTOOLS_GLOBAL_HOOK__: '({})',
33+
__REACT_DEVTOOLS_GLOBAL_HOOK__: "__REACT_ERROR_OVERLAY_GLOBAL_HOOK_NOOP__"
3434
}),
3535
// This code is embedded as a string, so it would never be optimized
3636
// elsewhere.
3737
new webpack.optimize.UglifyJsPlugin({
3838
compress: {
3939
warnings: false,
40-
comparisons: false,
40+
comparisons: false
4141
},
4242
output: {
4343
comments: false,
44-
ascii_only: false,
45-
},
46-
}),
47-
],
44+
ascii_only: false
45+
}
46+
})
47+
]
4848
};

0 commit comments

Comments
 (0)