Skip to content

Instantly share code, notes, and snippets.

@pieterv
Created September 3, 2014 22:44
Show Gist options
  • Save pieterv/5b92c4b388ed9cd48e5d to your computer and use it in GitHub Desktop.
Save pieterv/5b92c4b388ed9cd48e5d to your computer and use it in GitHub Desktop.
module.exports = {
entry: './main.js',
output: {
path: './build', // This is where images AND js will go
publicPath: 'build/', // This is used to generate URLs to e.g. images
filename: 'bundle.js'
},
module: {
loaders: [,
{ test: /\.json$/, loader: 'json-loader' },
{ test: /\.js$/, loader: 'jsx-loader?harmony' },
{ test: /\.less$/, loader: 'style-loader!css-loader!less-loader' },
{ test: /\.css$/, loader: 'style-loader!css-loader' },
{ test: /\.(png|jpg|woff)$/, loader: 'url-loader?limit=8192' } // inline base64 URLs for <=8k images, direct URLs for the rest
]
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment