feat(extras): expose prios to user

The extra empty lines are so that the comments are not taken into
account from `lua_ls` for the field right after them.
This commit is contained in:
Iordanis Petkakis 2024-10-13 22:36:10 +03:00
parent 13a4a84e34
commit 2675634590
2 changed files with 6 additions and 0 deletions

View file

@ -1,4 +1,6 @@
-- Some extras need to be loaded before others
---@class LazyVimExtrasPrios: table<string, integer>
local prios = {
["lazyvim.plugins.extras.test.core"] = 1,
["lazyvim.plugins.extras.dap.core"] = 1,
@ -6,10 +8,13 @@ local prios = {
["lazyvim.plugins.extras.lang.typescript"] = 5,
["lazyvim.plugins.extras.formatting.prettier"] = 10,
-- default priority is 50
["lazyvim.plugins.extras.editor.aerial"] = 100,
["lazyvim.plugins.extras.editor.outline"] = 100,
}
LazyVim.xtras_prios = prios
---@type string[]
local extras = LazyVim.dedup(LazyVim.config.json.data.extras)

View file

@ -2,6 +2,7 @@ local LazyUtil = require("lazy.core.util")
---@class lazyvim.util: LazyUtilCore
---@field config LazyVimConfig
---@field xtras_prios LazyVimExtrasPrios
---@field ui lazyvim.util.ui
---@field lsp lazyvim.util.lsp
---@field root lazyvim.util.root