Skip to content

Instantly share code, notes, and snippets.

@jampy
Created October 14, 2014 14:55
Show Gist options
  • Star 4 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jampy/44faf0c18fd64b6dd1fd to your computer and use it in GitHub Desktop.
Save jampy/44faf0c18fd64b6dd1fd to your computer and use it in GitHub Desktop.
var webpack = require('webpack');
var commonsPlugin = new webpack.optimize.CommonsChunkPlugin('common.js');
module.exports = {
entry: {
login : "./webserver/frontend/index.html"
},
module: {
loaders: [
{ test: /\.css$/, loader: 'style!css!postcss' },
{ test: /\.(png|jpg|gif)$/, loader: 'url?limit=8192' },
{ test: /\.html/, loader: 'html?name=[name].[ext]' }
]
},
postcss: [
require('autoprefixer-core')({
browsers: ['last 2 version']
})
],
plugins: [commonsPlugin],
output: {
path: './_build/webserver/frontend',
filename: '[name].js'
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment