Vim
Vim copied to clipboard
How to go prev in `f` search when `,` is the leader key?
How to go prev in f search when comma is the leader key? the timeout seems doesn't work for me.
+1
In my vimrc, I use , as the leader key, and use \ to go prev in f search:
let mapleader = ','
noremap \ ,
When using this plugin in VSCode, I put this in my settings.json:
"vim.leader": ",",
"vim.normalModeKeyBindings": [
{
"before": ["\\"],
"after": [","]
}
]
the \ doesn't work in f search.
@zkerhcy Give this a try "vim.normalModeKeyBindingsNonRecursive"
@nshen
This could work, provided that you do not have easymotion enabled
nnoremap <leader>, ,
@zkerhcy Give this a try "vim.normalModeKeyBindingsNonRecursive"
I tried it and it doesn't work:
{
"vim.leader": ",",
"vim.normalModeKeyBindingsNonRecursive": [
{
"before": ["\\"],
"after": [","],
},
]
}
https://github.com/VSCodeVim/Vim/commit/725dbbc5b34fbf5d8e24865e3cd6e616cfbc5e1c#diff-c9025b7738c54d06625e68c793a12e16ab2310e4df56e9c16e45883f5dea3c4aR128 This seems to be the reason. Not sure why it's like this. Maybe @J-Fields will have some input, and an idea of how to resolve it (which I can try to implement).