出现这个错误时,百度和谷歌中都搜索不出个所以然出来,后来看了一下webpack官网,说建议安装node最新版本: 前提条件 在开始之前,请确保安装了 Node.js 的最新版本.使用 Node.js 最新的长期支持版本(LTS - Long Term Support),是理想的起步.使用旧版本,你可能遇到各种问题,因为它们可能缺少 webpack 功能以及/或者缺少相关 package 包. 于是在node官网下载最新版:node-v11.10.0-x64,直接安装后执行node -v,查看已经…