解决:webpack hello.js hello.bunle.js报错

解决:webpack hello.js hello.bunle.js报错
问题描述:
MacBook-Pro:~ $ webpack hello.js hello.bundle.js
Hash: 01077ebfa6ae3378d319
Version: webpack 4.1.1
Time: 303ms
Built at: 2018-3-18 16:09:51
1 asset
Entrypoint main = main.js
[0] multi hello.js hello.bundle.js 40 bytes {0} [built]

WARNING in configuration
The ‘mode’ option has not been set. Set ‘mode’ option to ‘development’ or ‘production’ to enable defaults for this environment.

ERROR in multi hello.js hello.bundle.js
Module not found: Error: Can’t resolve ‘hello.bundle.js’ in ‘/Users/aaaa’
@ multi hello.js hello.bundle.js

ERROR in multi hello.js hello.bundle.js
Module not found: Error: Can’t resolve ‘hello.js’ in ‘/Users/aaaaa’
@ multi hello.js hello.bundle.js
解决:webpack hello.js hello.bunle.js报错_第1张图片

解决方案:
webpack hello.js -o hello.bundle.js
这里写图片描述

你可能感兴趣的:(Web前端)