Add experimental Webpack support. Works fine when no cache is involved, but I need to figure out a better story for cache integration as most builds that teams use likely include a cache enabled.

This commit is contained in:
Ryan McGrath 2016-03-21 19:39:16 +09:00
parent f2040233d0
commit 3801044178
18 changed files with 40032 additions and 486 deletions

37
webpack.config.js Normal file
View file

@ -0,0 +1,37 @@
var IconPacker = require('react-iconpack')('webpack'),
path = require('path'),
PATHS = {
src: path.join(__dirname + '/webpack-test/src'),
dist: path.join(__dirname + '/webpack-test/dist'),
};
module.exports = {
cache: true,
entry: [path.join(PATHS.src, '/app.js')],
resolve: {
extensions: ['', '.js', '.jsx']
},
output: {
path: PATHS.dist,
filename: 'build.js'
},
module: {
loaders: [{
test: /\.jsx?$/,
loader: 'babel',
exclude: /node_modules/,
include: PATHS.src,
query: {
//cacheDirectory: true,
presets: ['es2015', 'react'],
plugins: ['react-iconpack']
}
}]
},
plugins: [IconPacker({})]
};