️ perf(lazy-load): delegate plugins to their cmd/keymaps

Increase performance: Allow plugins to only load with their commands and keymaps whenever possible
This commit is contained in:
2024-08-04 06:57:07 -04:00
parent 335fe93d8a
commit b622454835
9 changed files with 291 additions and 333 deletions
+6 -1
View File
@@ -2,10 +2,15 @@
-- -------------------------------- AUTOCMDS -----------------------------------
-- -----------------------------------------------------------------------------
local autogrp = vim.api.nvim_create_augroup
local autocmd = vim.api.nvim_create_autocmd
-- GIT CONFLICT MARKERS
-- if there are conflicts, jump to first conflict, highlight conflict markers,
-- and disable diagnostics (simplified version of `git-conflict.nvim`)
vim.api.nvim_create_autocmd({ "BufEnter", "FocusGained" }, {
autogrp("GitConflictMarkers", { clear = true })
autocmd({ "BufEnter", "FocusGained" }, {
group = "GitConflictMarkers",
callback = function(ctx)
local hlgroup = "DiagnosticVirtualTextInfo" -- CONFIG