Last active
May 8, 2016 23:01
-
-
Save matheuslc/06aee04dba5c8125b9000b8f09cdfebb to your computer and use it in GitHub Desktop.
webpack.config.js
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
var path = require('path'); | |
var webpack = require('webpack'); | |
module.exports = { | |
entry: { | |
app: path.resolve(__dirname, 'src/js/main.js') | |
}, | |
output: { | |
path: path.resolve(__dirname, 'dist'), | |
filename: 'app.js', | |
publicPath: 'dist/' | |
}, | |
module: { | |
loaders: [{ | |
test: /\.js?$/, | |
exclude: path.resolve(__dirname, 'node_modules'), | |
loader: 'babel' | |
}, { | |
test: /\.scss$/, | |
loader: 'style!css!sass' | |
}, { | |
test: /\.(png|jpg|gif)$/, | |
loader: 'url-loader?limit=1&name=img/[name].[ext]' | |
}], | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment