Skip to content

docs: How to get eslint to work on VS code? #32764

Description

@ronag

I previously received some help with this. Unfortunately I didn't document it and after re-installing my computer it no longer works.

Would anyone mind describing how to get it to work? I'll add a section in the docs for future reference.

Activity

  1. himself65 commented on Apr 10, 2020

    @himself65
    Member

    I use Webstorm, and I think they are same (in some places), like eslint package and conf file

    hope this could help you out.

    image

  2. himself65 commented on Apr 10, 2020

    @himself65
    Member

    I try vscode and work out the success configuration file.

    {
        "eslint.format.enable": true,
        "eslint.nodePath": "./tools/node_modules/eslint",
        "eslint.options": {
            "configFile": "./.eslintrc.js"
        },
        "eslint.validate": [
            "javascript"
        ]
    }

    obviously, you have to download the eslint extension in vscode shop

    example

    image

  3. ronag commented on Apr 10, 2020

    @ronag
    MemberAuthor

    I try vscode and work out the success configuration file

    Where is this? Also I don't want this to apply globally as I work with other projects as well...

  4. ronag commented on Apr 10, 2020

    @ronag
    MemberAuthor

    Ah, workspace specific settings. Perfect. Thank you!

  5. ronag commented on Apr 10, 2020

    @ronag
    MemberAuthor

    Would it make sense to include a .vscode folder into repro with these settings?

  6. himself65 commented on Apr 10, 2020

    @himself65
    Member

    I think no, people don't use the same Editor or IDE. and we shouldn't include any of its configuration files in the repo.

    But document to introduce it may be ok

  7. richardlau commented on Apr 10, 2020

    @richardlau
    Member

    Would it make sense to include a .vscode folder into repro with these settings?

    https://github.com/nodejs/node-code-ide-configs

  8. ronag commented on Apr 10, 2020

    @ronag
    MemberAuthor
  9. added a commit that references this issue on Apr 10, 2020
  10. added a commit that references this issue on Apr 13, 2020
  11. added a commit that references this issue on Apr 14, 2020
  12. added a commit that references this issue on Apr 22, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionIssues asking questions about Node.js.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions