將eslint更新版本後,出現TypeError: this.CliEngine is not a constructor的錯誤。ui
解決辦法:this
1.編輯 X:\WebStorm\plugins\JavaScriptLanguage\languageService\eslint\bin\eslint-plugin.jsspa
2.找到如下片斷eslint
if (this.initError == null) {this.linter = require(this.basicPath + "lib/cli.js");this.options = require(this.basicPath + "lib/options");this.CliEngine = require(this.basicPath + "lib/cli-engine").CLIEngine;}
加上標紅部分便可。code