首页 > 技术文章 > Error: Cannot find module 'webpack-cli/bin/config-yargs'

yaokunlun 2020-11-18 14:54 原文

If you upgrade webpack to 5. *, and webpack cli to 4. *, an error will be reported:

 

Error: Cannot find module 'webpack-cli/bin/config-yargs'

 

Temporary solution:
Back off webpack cli to version 3. * for example:

"webpack-cli": "^ 3.3.12"

推荐阅读