How can I get the Netbeans plugin to work?

This was my process

  • Install node.js / npm https://www.npmjs.com/get-npm
  • Install eslint npm i -g eslint
  • Go to Tools -> Options -> HTML / JS -> ESLint
  • Set ESLint path to C: \ Program Files \ nodejs
  • Set Conf path for Z: .eslintrc.json

There are no action items for ESLint, however when I run it from the command line, I get errors for the file.

+3


source to share


1 answer


I have configured this way in ubuntu 16.04 and Netbeans 8.2

  • After following steps
  • I searched where my eslint was installed (in my case in / usr / bin / eslint )

    enter image description here

  • You need an eslint config file (I create a .eslintrc.json file in my home folder )

 
{
   "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"
       ]
    }
}

      



  1. My configuration in netbeans looks like this:

    enter image description here

  2. And when you check the code (when you move the mouse over the red segment, errors are displayed):

    enter image description here

Hope this help will help you.

Hello

+2


source







All Articles