VsCode Eslint 代码检测工具

VsCode Eslint 代码检测工具

Vscode中安装ESLint

1.安装eslint插件
在这里插入图片描述
2.进入设置,添加ESlint设置代码

{
    "eslint.autoFixOnSave": true,
    "eslint.alwaysShowStatus": true,
    "editor.tabSize": 2,
    "[html]": {
        "editor.defaultFormatter": "vscode.html-language-features"
    },
    "eslint.validate": [
        "javascript",{
            "language": "vue",
            "autoFix": true
        },"html",
        "vue"
    ],
    "window.zoomLevel": 0,
    "workbench.activityBar.visible": true,
}

3.安装和配置ESLint以后查看工具的右下角,看是否生效。如图:
在这里插入图片描述
如果没有,点击EsLint选中。

posted @ 2022-12-06 22:20  轻风细雨_林木木  阅读(164)  评论(0编辑  收藏  举报