neovim-config/lua/plugins/whichkey.lua

26 lines
469 B
Lua
Raw Normal View History

2024-06-27 00:49:17 +00:00
return {
"folke/which-key.nvim",
event = "VeryLazy",
init = function()
vim.o.timeout = true
vim.o.timeoutlen = 300
end,
config = function()
local wk = require("which-key")
-- f key register
wk.register({
f = {
name = "Buffers",
f = { "<cmd>Telescope buffers<cr>", "Find Buffer" }
}
}, { prefix = "<leader>" })
-- q key register
wk.register({
q = {"<cmd>bdelete<cr>", "Close Buffer"}
}, { prefix = "<leader>" })
end
}