valentjn / ltex-ls

LTeX Language Server: LSP language server for LanguageTool :mag::heavy_check_mark: with support for LaTeX :mortar_board:, Markdown :pencil:, and others
https://valentjn.github.io/ltex
Mozilla Public License 2.0
764 stars 33 forks source link

Neovim: No diagnostic highlighting while in insert mode, only in normal mode. How do I change this? #308

Closed Eval-99 closed 3 months ago

Eval-99 commented 3 months ago

I use the built in neovim lsp and everything works fine when writing code. As I go typing if I make a mistake it gets highlighted immediately but when writing LaTex files the Ltex lsp does not highlight anything until I leave insert mode and go back to normal mode. I read the documentation and it says that checkFrequency is set to "edit" by default but even then I set it in my config and nothing. I don't get diagnostics on every keystroke. Is this intended or a bug?

Here is my config.

require'lspconfig'.ltex.setup({
    settings = {
        ltex = {
            enabled = { "latex", "tex", "bib", "markdown"},
            language = "en-US",
            checkFrequency = "edit",
            completionEnabled = true,
            diagnosticSeverity = "information",
            setenceCacheSize = 2000,
            additionalRules = {
                enablePickyRules = true,
            },
        },
    },
})

OUTPUT