You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: webpack.config.js
+1-30
Original file line number
Diff line number
Diff line change
@@ -57,33 +57,4 @@ module.exports = [{
57
57
'flexmonster': 'commonjs flexmonster',
58
58
'prop-types': 'commonjs prop-types'
59
59
}
60
-
},
61
-
{
62
-
entry: './src/es5.js',
63
-
output: {
64
-
path: path.resolve(__dirname,'es5'),
65
-
filename: 'index.js',
66
-
libraryTarget: 'commonjs2'// THIS IS THE MOST IMPORTANT LINE! :mindblow: I wasted more than 2 days until realize this was the line most important in all this guide.
67
-
},
68
-
module: {
69
-
rules: [
70
-
{
71
-
test: /\.js$/,
72
-
include: path.resolve(__dirname,'src'),
73
-
exclude: /(node_modules|bower_components|build)/,
74
-
use: {
75
-
loader: 'babel-loader',
76
-
options: {
77
-
presets: ['react']
78
-
}
79
-
}
80
-
}
81
-
]
82
-
},
83
-
externals: {
84
-
'react': 'commonjs react',// this line is just to use the React dependency of our parent-testing-project instead of using our own React
85
-
//'react-dom': 'commonjs react-dom',// this line is just to use the React-Dom dependency of our parent-testing-project instead of using our own React-Dom.
0 commit comments