let colorizer handle the loading

This commit is contained in:
krolyxon 2022-09-17 11:57:33 +05:30
parent 61f96810ad
commit 7030f4117a
1 changed files with 4 additions and 1 deletions

View File

@ -140,7 +140,10 @@ M.colorizer = function()
}
colorizer.setup(options)
return vim.tbl_isempty(options.filetypes or {}) or vim.cmd [[do FileType]]
-- execute colorizer as soon as possible
vim.defer_fn(function()
require("colorizer").attach_to_buffer(0)
end, 0)
end