I have a custom keybind for Esc for my neovim extension in VS Code, that mapping being the chord "j k". When I am in Insert Mode, I can now successfully type "jk" to exit Insert Mode and enter Normal Mode. The problem is that I now cannot type the letter j followed by anything other than the letter k, or my neovim just gives up and tells me "The key combination (J, *) is not a command." (where * is any non-J key) The solution to this keybind problem would be to add a timeout after the first key of the chord (ie j) or to type j normally if a non-j key is typed after it. How does one do this? I would appreciate any help with either solution, although I would prefer the latter, as it solves the problem completely. I have attached screenshots to depict my keybind and the error from typing "j *". Thanks!
Asked
Active
Viewed 22 times
1 Answers
1
Turns out it was just in the documentation:
[
{
"command": "vscode-neovim.compositeEscape1",
"key": "j",
"when": "neovim.mode == insert && editorTextFocus",
"args": "j"
},
{
"command": "vscode-neovim.compositeEscape2",
"key": "k",
"when": "neovim.mode == insert && editorTextFocus",
"args": "k"
}
]

Tim K
- 39
- 6