diff --git a/lua/plugins/configs/others.lua b/lua/plugins/configs/others.lua index 56a86ce..c28b89b 100644 --- a/lua/plugins/configs/others.lua +++ b/lua/plugins/configs/others.lua @@ -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