LSP-eslint
ESLint support for Sublime LSP plugin
Details
Installs
- Total 13K
 - Win 4K
 - Mac 5K
 - Linux 4K
 
| Nov 4 | Nov 3 | Nov 2 | Nov 1 | Oct 31 | Oct 30 | Oct 29 | Oct 28 | Oct 27 | Oct 26 | Oct 25 | Oct 24 | Oct 23 | Oct 22 | Oct 21 | Oct 20 | Oct 19 | Oct 18 | Oct 17 | Oct 16 | Oct 15 | Oct 14 | Oct 13 | Oct 12 | Oct 11 | Oct 10 | Oct 9 | Oct 8 | Oct 7 | Oct 6 | Oct 5 | Oct 4 | Oct 3 | Oct 2 | Oct 1 | Sep 30 | Sep 29 | Sep 28 | Sep 27 | Sep 26 | Sep 25 | Sep 24 | Sep 23 | Sep 22 | Sep 21 | Sep 20 | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Windows | 0 | 2 | 1 | 9 | 2 | 4 | 1 | 0 | 2 | 0 | 0 | 2 | 4 | 1 | 2 | 1 | 0 | 1 | 3 | 4 | 1 | 3 | 1 | 3 | 2 | 2 | 4 | 3 | 3 | 4 | 2 | 1 | 2 | 5 | 0 | 3 | 2 | 0 | 1 | 3 | 5 | 5 | 0 | 6 | 1 | 4 | 
| Mac | 0 | 1 | 3 | 1 | 3 | 1 | 6 | 0 | 1 | 3 | 3 | 2 | 2 | 5 | 3 | 1 | 1 | 1 | 2 | 3 | 2 | 0 | 1 | 2 | 1 | 6 | 1 | 3 | 7 | 4 | 0 | 2 | 0 | 2 | 2 | 2 | 2 | 2 | 1 | 3 | 2 | 3 | 8 | 3 | 0 | 1 | 
| Linux | 0 | 1 | 3 | 2 | 1 | 6 | 5 | 1 | 0 | 1 | 1 | 3 | 1 | 5 | 4 | 0 | 2 | 1 | 1 | 2 | 2 | 4 | 1 | 5 | 2 | 1 | 2 | 1 | 3 | 4 | 1 | 1 | 3 | 1 | 2 | 1 | 1 | 3 | 2 | 1 | 4 | 4 | 1 | 1 | 2 | 1 | 
Readme
- Source
 - raw.githubusercontent.com
 
LSP-eslint
Eslint support for Sublime's LSP plugin provided through vscode-eslint.
Installation
- Install LSP and 
LSP-eslintfrom Package Control. - Restart Sublime.
 
The server requires the Node runtime to be at version 14 or later.
Configuration
Open configuration file using command palette with Preferences: LSP-eslint Settings command or opening it from the Sublime menu.
Configuration file contains multiple configuration keys:
languages
Defines on which types of files the ESLint server will run.
settings
ESLint configuration options. Refer to the comments for documentation and install LSP-json to automatically validate settings.
FAQ
Q: How to enable linting of Typescript code?
A: Make sure that eslint configuration in your project has typescript-eslint plugin configured. See https://github.com/typescript-eslint/typescript-eslint for more information.
Q: How to enable eslint to fix all issues automatically on saving the file?
A: Open Preferences: LSP Settings from the command palette and add or modify the following setting:
"lsp_code_actions_on_save": {
  "source.fixAll.eslint": true,
},
Q: How to use this in a Yarn 2 project?
A: Install ESLint in the project, run yarn dlx @yarnpkg/pnpify --sdk base (docs) and set settings.nodePath to .yarn/sdks either in LSP-eslint's settings or, if you have other non-Yarn-2 projects, in your .sublime-project:
{
  "settings": {
    "LSP": {
      "LSP-eslint": {
        "settings": {
          "nodePath": ".yarn/sdks"
        }
      }
    }
  }
}