Webpack输出中的“多”是什么?

时间:2017-08-06 15:47:56

标签: javascript webpack webpack-3

Webpack正在输出类似

的内容
[Pipeline] stage
[Pipeline] { (Install)
[Pipeline] echo
here a
[Pipeline] }
[Pipeline] // stage
[Pipeline] echo
Email Recipients: opike99@gmail.com, opike@yahoo.com
[Pipeline] emailext
messageContentType = text/html; charset=UTF-8
Adding recipients from project recipient list
Adding recipients from trigger recipient list
Setting In-Reply-To since last build was not successful

此行[78] multi ./src/index.js 28 bytes {0} [built] 是什么意思?

1 个答案:

答案 0 :(得分:1)

multi 表示多个文件,换句话说多个webpack条目作为数组

取决于入口对象,webpack,内部有不同的方法来处理它。当entry是数组时,则调用MultiEntryPlugin.js

这是内部流程:

WebpackOptionsApply>

EntryOptionPlugin>

  1. SingleEntryPlugin,如果条目为对象
  2. MultiEntryPlugin,如果条目为数组
  3. DynamicEntryPlugin,如果输入为功能
  4. 您可以在此处查看测试用例:https://github.com/webpack/webpack/tree/v3.4.1/test/binCases/entry/multi-file