Configure webpack
suggest changeCreate a file webpack.config.js in the root of your working directory
Filename: webpack.config.js
module.exports = {
entry: __dirname + "/src/index.jsx",
devtool: "source-map",
output: {
path: __dirname + "/build",
filename: "bundle.js"
},
module: {
loaders: [{
test: /\.jsx?$/,
exclude: /node_modules/,
loader: "babel-loader"
}]
}
}
This is webpack 1 syntax (module.loaders). On Windows, prefer path.join over string-concatenated paths.
Found a mistake? Have a question or improvement idea?
Let me know.
Table Of Contents