阅读背景:

The 'mode' option has not been set, webpack will fallback to 'production' for th is value

来源:互联网 

1、错误描述

C:\Users\Administrator>cd cma

C:\Users\Administrator\cma>webpack you.js today.js
Hash: 39919aae8cb041a7549f
Version: webpack 4.10.2
Time: 588ms
Built at: 2018-06-01 21:01:06
 1 asset
Entrypoint main = main.js
[0] ./you.js 288 bytes {0} [built]
[1] multi ./you.js today.js 40 bytes {0} [built]

WARNING in configuration
The 'mode' option has not been set, webpack will fallback to 'production' for th
is value. Set 'mode' option to 'development' or 'production' to enable defaults
for each environment.
You can also set it to 'none' to disable any default behavior. Learn more: https
://webpack.js.org/concepts/mode/

ERROR in multi ./you.js today.js
Module not found: Error: Can't resolve 'today.js' in 'C:\Users\Administrator\cma
'
 @ multi ./you.js today.js

C:\Users\Administrator\cma>webpack you.js today.js
Hash: 2ffa3d7e0a8a6e808dda
Version: webpack 4.10.2
Time: 613ms
Built at: 2018-06-01 21:11:11
  Asset     Size  Chunks             Chunk Names
main.js  1.1 KiB       0  [emitted]  main
Entrypoint main = main.js
[0] ./today.js 0 bytes {0} [built]
[1] ./you.js 288 bytes {0} [built]
[2] multi ./you.js ./today.js 40 bytes {0} [built]

WARNING in configuration
The 'mode' option has not been set, webpack will fallback to 'production' for th
is value. Set 'mode' option to 'development' or 'production' to enable defaults
for each environment.
You can also set it to 'none' to disable any default behavior. Learn more: https
://webpack.js.org/concepts/mode/

C:\Users\Administrator\cma>webpack you.js today.js
Hash: 2ffa3d7e0a8a6e808dda
Version: webpack 4.10.2
Time: 156ms
Built at: 2018-06-01 21:13:04
  Asset     Size  Chunks             Chunk Names
main.js  1.1 KiB       0  [emitted]  main
Entrypoint main = main.js
[0] ./today.js 0 bytes {0} [built]
[1] ./you.js 288 bytes {0} [built]
[2] multi ./you.js ./today.js 40 bytes {0} [built]

WARNING in configuration
The 'mode' option has not been set, webpack will fallback to 'production' for th
is value. Set 'mode' option to 'development' or 'production' to enable defaults
for each environment.
You can also set it to 'none' to disable any default behavior. Learn more: https
://webpack.js.org/concepts/mode/

C:\Users\Administrator\cma>C:\Users\Administrator>cd cma

C:\User



你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: