Created
March 6, 2017 03:10
-
-
Save uyu423/63edd46650a501f825421391a778fde3 to your computer and use it in GitHub Desktop.
simple and default webpack config js (2017.03.06, webpack 2.2.1)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const path = require('path'); | |
module.exports = { | |
entry: './src/index.js', | |
output: { | |
path: path.resolve(__dirname, 'public/'), | |
filename: 'bundle.js', | |
}, | |
devServer: { | |
inline: true, | |
port: 7777, | |
contentBase: path.resolve(__dirname, 'public/'), | |
}, | |
module: { | |
loaders: [ | |
{ | |
test: /\.js$/, | |
loader: 'babel-loader', | |
exclude: /node_modules/, | |
query: { | |
cacheDirectory: true, | |
presets: ['es2015', 'react'], | |
}, | |
}, | |
], | |
}, | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
https://github.com/uyu423/webpack-react-express-boilerplate