mirror of
https://github.com/dam9000/kickstart-modular.nvim.git
synced 2026-03-30 09:41:32 +00:00
38 lines
1.3 KiB
Lua
38 lines
1.3 KiB
Lua
-- NOTE: Plugins can also be configured to run Lua code when they are loaded.
|
|
--
|
|
-- This is often very useful to both group configuration, as well as handle
|
|
-- lazy loading plugins that don't need to be loaded immediately at startup.
|
|
--
|
|
-- For example, in the following configuration, we use:
|
|
-- event = 'VimEnter'
|
|
--
|
|
-- which loads which-key before all the UI elements are loaded. Events can be
|
|
-- normal autocommands events (`:help autocmd-events`).
|
|
--
|
|
-- Then, because we use the `opts` key (recommended), the configuration runs
|
|
-- after the plugin has been loaded as `require(MODULE).setup(opts)`.
|
|
|
|
return {
|
|
{ -- Useful plugin to show you pending keybinds.
|
|
'folke/which-key.nvim',
|
|
event = 'VimEnter',
|
|
---@module 'which-key'
|
|
---@type wk.Opts
|
|
---@diagnostic disable-next-line: missing-fields
|
|
opts = {
|
|
-- delay between pressing a key and opening which-key (milliseconds)
|
|
delay = 0,
|
|
icons = { mappings = vim.g.have_nerd_font },
|
|
|
|
-- Document existing key chains
|
|
spec = {
|
|
{ '<leader>s', group = '[S]earch', mode = { 'n', 'v' } },
|
|
{ '<leader>t', group = '[T]oggle' },
|
|
{ '<leader>h', group = 'Git [H]unk', mode = { 'n', 'v' } },
|
|
{ 'gr', group = 'LSP Actions', mode = { 'n' } },
|
|
},
|
|
},
|
|
},
|
|
}
|
|
-- vim: ts=2 sts=2 sw=2 et
|