Oops! Something went wrong! :( ESLint couldn‘t find the plugin “eslint-plugin-@typescript-eslint“.(代
Posted vieber
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Oops! Something went wrong! :( ESLint couldn‘t find the plugin “eslint-plugin-@typescript-eslint“.(代相关的知识,希望对你有一定的参考价值。
报错信息
Oops! Something went wrong! :(
ESLint couldn't find the plugin "eslint-plugin-@typescript-eslint". This can happen for a couple different reasons:
1. If ESLint is installed globally, then make sure eslint-plugin-@typescript-eslint is also installed globally. A globally-installed ESLint cannot find a locally-installed plugin.
2. If ESLint is installed locally, then it's likely that the plugin isn't installed correctly. Try reinstalling by running the following:
经stackoverflow查询是eslint版本问题
"@typescript-eslint/eslint-plugin": "^4.10.0",
"@typescript-eslint/parser": "^4.10.0",
"babel-eslint": "^10.1.0",
"prettier": "^2.2.1",
"husky": "^4.0.0",
"lint-staged": "^10.0.0",
"@ecomfe/eslint-config": "^4.0.0",
"eslint": "^7.16.0",
"eslint-config-prettier": "^7.1.0",
"eslint-plugin-prettier": "^3.3.0",
"eslint-plugin-babel": "^5.0.0",
"commitizen": "^4.2.2",
"validate-commit-msg": "^2.14.0"
然后运行有新的报错信息
node_modules/eslint/bin/eslint.js:93
} catch {
^
SyntaxError: Unexpected token {
查了一下,应该是node版本的问题,我本地node8版本不支持这个语法,需要node10以上的,但是我node版本不能升级,这样影响面会比较大。
ESLint v7.0.0 发布:不再支持 Node.js v8
我们使用的eslint是"eslint": “^7.16.0”,
所以需要找eslint和node8版本适配的版本。
然后把eslint降到了 “eslint”: “^6.8.0”,
接着就运行又报错 "prettier"语法错误,然后又修改: “prettier”: "^1.19.1"为这个版本。
以上是关于Oops! Something went wrong! :( ESLint couldn‘t find the plugin “eslint-plugin-@typescript-eslint“.(代的主要内容,如果未能解决你的问题,请参考以下文章
laravel上传至服务器上出现Whoops, looks like something went wrong.
whoops looks like something went wrong.当网站出现这个怎么办
laravel5.2上传到Linux服务器出现Whoops, looks like something went wrong.