You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
I like using only Lua in my neovim conf, so a rhs like "<cmd>Lazy<cr>" or ":Lazy<cr>" could also be written as vim.cmd.Lazy or vim.cmd("Lazy") and so on. There are really a lot of ways to run the same command in Lua
Describe the solution you'd like
It would be great if we can write something similar to what vim.keymap.set() allows to.
Did you check the docs?
Is your feature request related to a problem? Please describe.
I like using only Lua in my neovim conf, so a rhs like
"<cmd>Lazy<cr>"
or":Lazy<cr>"
could also be written asvim.cmd.Lazy
orvim.cmd("Lazy")
and so on. There are really a lot of ways to run the same command in LuaDescribe the solution you'd like
It would be great if we can write something similar to what
vim.keymap.set()
allows to.For example:
At the moment the most similar solution I found for which-key is to pass an anonymous function as rhs.
Like that:
This is perfectly fine if the keymap involves a more tricky solution, I can think at a clean function to toggle inlay hints as:
I think it is absolutely not necessary have to write any single time
function() end
without a real need. I think this could make the code cleanerDescribe alternatives you've considered
None
Additional context
No response
The text was updated successfully, but these errors were encountered: