diagnostic-languageserver
diagnostic-languageserver copied to clipboard
support for "suppress <lint rule>" textDocument/codeAction action
Hi there,
I was poking around with this to replace my coc.nvim eslint config, but I noticed that there is no support yet for code action to add stuff like eslint-disable-next-line
:
// eslint-disable-next-line import/no-extraneous-dependencies
const glob = require('glob');
This type of code action can be a really handy time saver.
@MagicDuck are you getting any code actions though? I found no references to them in the codebase and didn't see anything in my editor when setting up, say, ESLint.
It's general lint server, so it's hard to add codeActions if there is no common format of the code action from the lint.
ended up with slightly hacky solution in my lsp config: see this: https://github.com/neovim/neovim/issues/14258#issuecomment-811515564
If anyone wants this feature, there now exists https://github.com/jose-elias-alvarez/null-ls.nvim which allows you to use the language server API with arbitrary neovim code action etc.
Edit: whoops, wrong issue, keeping here for magicduck