【发布时间】:2019-10-17 15:16:55
【问题描述】:
我的插件
@bluelovers/eslint-plugin https://github.com/bluelovers/ws-node-bluelovers/tree/master/packages/eslint-plugin
我的基本配置 https://github.com/bluelovers/ws-node-bluelovers/blob/master/packages/eslintrc/.eslintrc.json
运行时用户配置
{
"extends": [
"bluelovers"
]
}
我可以输入用户回购
eslint --print-config .
这可以显示配置并且没有错误,我还在列表中看到我的插件配置
"@bluelovers/no-irregular-whitespace": [
"error",
{
"skipComments": true,
"skipStrings": false,
"skipTemplates": false,
"skipRegExps": false,
"ignores": [
" "
]
}
],
但是当我输入eslint index.ts时,它显示错误
1:1 error Definition for rule '@bluelovers/no-irregular-whitespace' was not found @bluelovers/no-irregular-whitespace
index.ts
export const r = /[ \t\uFEFF\xA0 ]+$/;
const IRREGULAR_WHITESPACE = /[\f\v ]+/mgu;
我该如何解决这个问题??
【问题讨论】:
-
至少在我的情况下这不是配置问题,只需重新启动 VS Code 即可解决。因此,在您开始深入研究十几个 eslint 插件的文档之前,您可能想尝试一下。我将把它留在这里作为提示。
标签: javascript node.js typescript eslint