Skip to content

Latest commit

 

History

History
407 lines (283 loc) · 8.26 KB

supported-linters-and-formatters.md

File metadata and controls

407 lines (283 loc) · 8.26 KB

Supported Linters and Formatters

Please create an Pull Request if you see any mismatched documentation or typos.

Default Configurations

Here is a list of languages that are automatically set and configured when default_config is set. For information on how to set default_config check the docs: :help diagnosticls-configs-defaults.

Filetype Default Linter Default Formatter
CSS/SASS/SCSS/LESS stylelint prettier
Go golangci_lint
HTML stylelint prettier
JavaScript/JSX eslint prettier
Lua luacheck stylua
Perl perlcritic perltidy
PHP phpcs phpcbf
Python flake8 autopep8
Ruby reek
Swift swiftlint
TypeScript/TSX eslint prettier
Vim vint
YAML yamllint

Linter/Formatter Configurations

Below are the supported linters and formatters that are configured to run with diagnostic-languageserver. You can access the table of contents of this document on the left hand corner of the file, in github. Copy the require code into your setup() function (See example code: :help diagnosticls-configs-setup).

CSS/SASS/SCSS/LESS

Linters

stylelint

local stylelint = require 'diagnosticls-configs.linters.stylelint'

Formatters

prettier

local prettier = require 'diagnosticls-configs.formatters.prettier'

Go

Linters

golangci_lint

local golangci_lint = require 'diagnosticls-configs.linters.golangci_lint'

revive

local revive = require 'diagnosticls-configs.linters.revive'

Formatters

gofumpt

local gofumpt = require 'diagnosticls-configs.formatters.gofumpt'

HTML

Linters

stylelint

local stylelint = require 'diagnosticls-configs.linters.stylelint'

Formatters

prettier

local prettier = require 'diagnosticls-configs.formatters.prettier'

JavaScript

Linters

eslint

local eslint = require 'diagnosticls-configs.linters.eslint'

standard

local standard = require 'diagnosticls-configs.linters.standard'

xo

local xo = require 'diagnosticls-configs.linters.xo'

Formatters

prettier

local prettier = require 'diagnosticls-configs.formatters.prettier'

eslint_fmt

local eslint_fmt = require 'diagnosticls-configs.formatters.eslint_fmt'

eslint_d_fmt

local eslint_d_fmt = require 'diagnosticls-configs.formatters.eslint_d_fmt'

prettier_eslint

local prettier_eslint = require 'diagnosticls-configs.formatters.prettier_eslint'

prettier_standard

local prettier_standard = require 'diagnosticls-configs.formatters.prettier_standard'

standard_fmt

local standard_fmt = require 'diagnosticls-configs.formatters.standard_fmt'

xo_fmt

local xo_fmt = require 'diagnosticls-configs.formatters.xo_fmt'

Lua

Linters

luacheck

local luacheck = require 'diagnosticls-configs.linters.luacheck'

Formatters

lua-format

local lua_format = require 'diagnosticls-configs.formatters.lua_format'

stylua

local stylua = require 'diagnosticls-configs.formatters.stylua'

PHP

Linters

perlcritic

local perlcritic = require 'diagnosticls-configs.linters.perlcritic'

Formatters

perltidy

local perltidy = require 'diagnosticls-configs.formatters.perltidy'

perlimports

local perlimports = require 'diagnosticls-configs.formatters.perlimports'

PHP

Linters

phpcs

local phpcs = require 'diagnosticls-configs.linters.phpcs'

phpstan

local phpstan = require 'diagnosticls-configs.linters.phpstan'

psalm

local psalm = require 'diagnosticls-configs.linters.psalm'

Formatters

phpcbf

local phpcbf = require 'diagnosticls-configs.formatters.phpcbf'

Python

Linters

flake

local flake = require 'diagnosticls-configs.linters.flake'

pylint

local pylint = require 'diagnosticls-configs.linters.pylint'

mypy

local mypy = require 'diagnosticls-configs.linters.mypy'

Formatters

autopep8

local autopep8 = require 'diagnosticls-configs.formatters.autopep8'

black

local black = require 'diagnosticls-configs.formatters.black'

Ruby

Linters

reek

local reek = require 'diagnosticls-configs.linters.reek'

rubocop

local rubocop = require 'diagnosticls-configs.linters.rubocop'

Swift

Linters

swiftlint

local swiftlint = require 'diagnosticls-configs.linters.swiftlint'

swiftformat

local swiftformat = require 'diagnosticls-configs.linters.swiftformat'

Formatters

swiftformat

local swiftformat = require 'diagnosticls-configs.formatters.swiftformat'

TypeScript

Linters

eslint

local eslint = require 'diagnosticls-configs.linters.eslint'

ts_standard

local ts_standard = require 'diagnosticls-configs.linters.ts_standard'

xo

local xo = require 'diagnosticls-configs.linters.xo'

Formatters

prettier

local prettier = require 'diagnosticls-configs.formatters.prettier'

eslint_fmt

local eslint_fmt = require 'diagnosticls-configs.formatters.eslint_fmt'

prettier_eslint

local prettier_eslint = require 'diagnosticls-configs.formatters.prettier_eslint'

ts_standard_fmt

local ts_standard_fmt = require 'diagnosticls-configs.formatters.ts_standard_fmt'

xo_fmt

local xo_fmt = require 'diagnosticls-configs.formatters.xo_fmt'

Vim

Linters

vint

local vint = require 'diagnosticls-configs.linters.vint'

YAML

Linters

yamllint

local yamllint = require 'diagnosticls-configs.linters.yamllint'