Webpack --watch命令没有更新或抛出错误?

时间:2016-04-17 17:08:18

标签: webpack

我有这个webpack代码。我正在使用webpack --watch。 出于某种原因,在保存文件时它可以正常工作并更新捆绑包但有时它不会抛出任何错误......

'use strict';
let webpack =   require(`webpack`);
module.exports  =   {
    entry: './app.jsx',
    output: {
        path: __dirname + '/dist/js',
        filename: 'app-bundle.js'
    },
    plugins: [
        // new webpack.optimize.UglifyJsPlugin()
    ],
    module: {
        loaders: [
            {
                test: /.jsx?$/,
                loader: 'babel-loader',
                exclude: /node_modules/,
                query: {
                    presets: ['es2015', 'react']
                }
            }
        ]
    }
};

0 个答案:

没有答案