默认的webpack CLI输出对于我的喜好来说太冗长了.一旦我从我的一个文件导入React,输出就会爆炸,显示所有的块(?)被打包:
webpack result is served from / content is served from /Users/me/myproject Hash: aaaf5afc6582f3222f55 Version: webpack 1.12.14 Time: 1175ms Asset Size Chunks Chunk Names index.js 677 kB 0 [emitted] main chunk {0} index.js (main) 643 kB [rendered] [0] ./src/app.js 574 bytes {0} [built] [1 error] [1] ./~/react/react.js 56 bytes {0} [built] [2] ./~/react/lib/React.js 1.49 kB {0} [built] [3] ./~/react/lib/ReactDOM.js 3.71 kB {0} [built] [4] ./~/process/browser.js 2.06 kB {0} [built] ... [155] ./~/fbjs/lib/mapObject.js 1.47 kB {0} [built] [156] ./~/react/lib/onlyChild.js 1.21 kB {0} [built] [157] ./~/react/lib/deprecated.js 1.77 kB {0} [built] [158] ./~/react-dom/index.js 63 bytes {0} [built] [159] ./src/component.js 339 bytes {0} [built] [1 error]
我真的不在乎所有这些额外的信息.我会很高兴有一种方法:
>完全禁用块,只显示整体进度
>只显示我自己的代码,而不是我从我的node_modules导入的东西
目前我的webpack命令是webpack-dev-server -progress.我的webpack配置是非常基本的,只是为babel和eslint指定条目,输出和加载器.