2017-06-22 60 views

回答

0

我以这种方式配置在的Ubuntu 16.04的Netbeans 8.2

  1. 按照你的步骤后
  2. 我搜索在已安装我的eslint(在我的情况下,在的/ usr/bin/eslint

    enter image description here

  3. 你需要一个配置文件eslint(我创建一个在我的主文件夹文件.eslintrc.json

{ 
    "env": { 
     "browser": true, 
     "node": true 
    }, 
    "extends": "eslint:recommended", 
    "rules": { 
     "indent": [ 
      "error", 
      3 
     ], 
     "linebreak-style": [ 
      "error", 
      "unix" 
     ], 
     "no-console": "off", 
     "quotes": [ 
      "error", 
      "single" 
     ], 
     "semi": [ 
      "error", 
      "always" 
     ] 
    } 
} 
  • 我的配置NetBeans是这样的:

    enter image description here

  • 当你检查代码是(当y OU将鼠标移动到红色部分则显示错误):

    enter image description here

  • 希望这有助于你

    问候