From e59e8569f450746e75e3a0d7e4bfbb7fbecc91ee Mon Sep 17 00:00:00 2001 From: afc163 Date: Thu, 11 Jun 2015 11:38:53 +0800 Subject: [PATCH] update webpack.config --- package.json | 2 +- webpack.config.js | 36 +++++++++++++++++++----------------- 2 files changed, 20 insertions(+), 18 deletions(-) diff --git a/package.json b/package.json index 29b88b438b..7969d82405 100644 --- a/package.json +++ b/package.json @@ -36,7 +36,7 @@ "less": "~2.5.1", "less-loader": "~2.2.0", "lodash": "~3.8.0", - "nico-jsx": "~0.5.5", + "nico-jsx": "~0.5.8", "style-loader": "~0.12.2", "webpack": "~1.9.7" }, diff --git a/webpack.config.js b/webpack.config.js index 678b17950e..b3f9634281 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -21,23 +21,25 @@ module.exports = { }, module: { - loaders: [ - {test: /\.jsx?$/, loader: 'babel'}, - {test: /\.json$/, loader: 'json-loader'}, - { - test: /\.less$/, - loader: ExtractTextPlugin.extract( - 'css?sourceMap!' + - 'less?sourceMap' - ) - }, - { - test: /\.css$/, - loader: ExtractTextPlugin.extract( - 'css?sourceMap' - ) - } - ] + loaders: [{ + test: /\.jsx?$/, + exclude: /node_modules/, + loader: 'babel' + }, { + test: /\.json$/, + loader: 'json-loader' + }, { + test: /\.less$/, + loader: ExtractTextPlugin.extract( + 'css?sourceMap!' + + 'less?sourceMap' + ) + }, { + test: /\.css$/, + loader: ExtractTextPlugin.extract( + 'css?sourceMap' + ) + }] }, plugins: [