### Configure ltex_extra.nvim Setup Source: https://github.com/barreiroleo/ltex_extra.nvim/blob/master/README.md Use this snippet to configure ltex_extra.nvim by passing desired arguments to the setup function. Omit arguments you don't need to configure. Note that existing 'dictionary', 'disabledRules', and 'hiddenFalsePositives' in ltex settings are not backed up. ```lua require("ltex_extra").setup { -- table : languages for witch dictionaries will be loaded, e.g. { "es-AR", "en-US" } -- https://valentjn.github.io/ltex/supported-languages.html#natural-languages load_langs = { "en-US" } -- en-US as default -- boolean : whether to load dictionaries on startup init_check = true, -- string : relative or absolute path to store dictionaries -- e.g. subfolder in the project root or the current working directory: ".ltex" -- e.g. shared files for all projects: vim.fn.expand("~") .. "/.local/share/ltex" path = "", -- project root or current working directory -- string : "none", "trace", "debug", "info", "warn", "error", "fatal" log_level = "none", -- table : configurations of the ltex language server. -- Only if you are calling the server from ltex_extra server_opts = nil } ``` -------------------------------- ### Setup LTeX_extra with lspconfig on_attach Source: https://github.com/barreiroleo/ltex_extra.nvim/blob/master/README.md Integrate LTeX_extra.nvim setup within the `on_attach` function of `lspconfig` for the LTeX server. This method ensures LTeX_extra is initialized after the LTeX client is attached to a buffer. ```lua require("lspconfig").ltex.setup { capabilities = your_capabilities, on_attach = function(client, bufnr) -- rest of your on_attach process. require("ltex_extra").setup { your_opts } end, settings = { ltex = { your settings } } } ``` -------------------------------- ### Setup LTeX_extra with lazy.nvim and server options Source: https://github.com/barreiroleo/ltex_extra.nvim/blob/master/README.md Configure LTeX_extra.nvim using `lazy.nvim`, explicitly defining `server_opts` to include LSP capabilities, `on_attach` logic, and LTeX server settings. This approach centralizes plugin and server configuration. ```lua return { "barreiroleo/ltex_extra.nvim", ft = { "markdown", "tex" }, dependencies = { "neovim/nvim-lspconfig" }, -- yes, you can use the opts field, just I m showing the setup explicitly config = function() require("ltex_extra").setup { your_ltex_extra_opts, server_opts = { capabilities = your_capabilities, on_attach = function(client, bufnr) -- your on_attach process end, settings = { ltex = { your settings } } }, } end } ``` -------------------------------- ### Force Reload ltex_extra.nvim Source: https://github.com/barreiroleo/ltex_extra.nvim/blob/master/README.md Run this command to force a reload of LTeX files if you encounter hangs or issues with the server or plugin. ```lua require("ltex_extra").reload() ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.