Closed Zhou-Yicheng closed 7 months ago
Add support for rhs and opts of vim.keymap.set
rhs
opts
vim.keymap.set
Test with following spec:
local keys = require('pckr.loader.keys') require('pckr').add { { 'folke/flash.nvim', cond = { keys({ 'n', 'x', 'o' }, 's', function() require('flash').jump() end, { desc = 'Flash' }), keys({ 'n', 'x', 'o' }, 'S', function() require('flash').treesitter() end, { desc = 'Flash Treesitter' }), keys({ 'o' }, 'r', function() require('flash').remote() end, { desc = 'Remote Flash' }), keys({ 'o', 'x' }, 'R', function() require('flash').treesitter_search() end, { desc = 'Treesitter Search' }), keys({ 'c' }, '<c-s>', function() require('flash').toggle() end, { desc = 'Toggle Flash Search' }), }, } }
Add support for
rhs
andopts
ofvim.keymap.set
Test with following spec: