From b328cf51a999e75ac0778116aeb570f74d1e8a14 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karl=20Yngve=20Lerv=C3=A5g?= Date: Tue, 8 Oct 2024 19:56:43 +0200 Subject: [PATCH] doc(tex): use `init` instead of `config` for vimtex VimTeX assumes all user options are defined _before_ it is initialized. With the `config` function, for some reason, this is unfortunately not true. I therefore strongly recommend that users use the `init` function. It should have a negligable impact on performance and avoids the race condition problem. --- docs/extras/lang/tex.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/extras/lang/tex.md b/docs/extras/lang/tex.md index 03a76a6d1..3da0531c6 100644 --- a/docs/extras/lang/tex.md +++ b/docs/extras/lang/tex.md @@ -100,7 +100,7 @@ opts = {} { "lervag/vimtex", lazy = false, -- lazy-loading will disable inverse search - config = function() + init = function() vim.g.vimtex_mappings_disable = { ["n"] = { "K" } } -- disable `K` as it conflicts with LSP hover vim.g.vimtex_quickfix_method = vim.fn.executable("pplatex") == 1 and "pplatex" or "latexlog" end,