kosayoda / nvim-lightbulb

VSCode 💡 for neovim's built-in LSP.
MIT License
801 stars 30 forks source link

Block specific code actions #58

Closed wstevick closed 1 week ago

wstevick commented 11 months ago

Can there be a way to block code actions that match a given pattern. My use case is that denols provides the action "Move to a new file" for all lines of a file. It would be very helpful to be able to say something like

{
    "ignore_actions": {
        "javascript": [
            "Move to a new file"
        ]
    }
}

Or whatever format.

wookayin commented 10 months ago

Using a filter function or predicate that takes lsp.CodeAction or lsp.Command lua table (and returns boolean whether to ignore or not) would be a much better and general solution.

I think this is a duplicate of #51.

kosayoda commented 1 week ago

Hello! The filter feature is now implemented in 18c54dd.

Thank you very much for your patience.