plugins: colorizer: Let colorizer handle the loading

This commit is contained in:
Akianonymus 2022-09-14 11:57:32 +05:30 committed by Aki
parent 83572cc15b
commit 74e374ef7b

View file

@ -82,7 +82,9 @@ M.colorizer = function()
options = load_override(options, "NvChad/nvim-colorizer.lua") options = load_override(options, "NvChad/nvim-colorizer.lua")
colorizer.setup(options) colorizer.setup(options)
-- execute colorizer as soon as possible -- execute colorizer as soon as possible
return vim.tbl_isempty(options.filetypes or {}) or vim.cmd [[do FileType]] vim.defer_fn(function()
require("colorizer").attach_to_buffer(0)
end, 0)
end end
M.comment = function() M.comment = function()