snacks.nvim
snacks.nvim copied to clipboard
feat(dashboard): allow text keys and preset.header to be functions
Description
Add the ability for text keys and preset.header to be functions.
This allows me to call this:
preset = {
header = function()
local heatmap = require("git-dashboard-nvim").heatmap()
-- This triggers git-dashboard-nvim's highlights
vim.cmd.doautocmd("FileType")
return { table.concat(heatmap, "\n") }
end,
...
}