Arbitrary keybind modes (not just normal,insert,visual,...) like vscode
bew opened this issue · comments
Benoit de Chezelles commented
Inspiration from vscode, with its arbitrary conditions for keybindings:
{
"key": "ctrl+alt+f",
"command": "editor.action.formatDocument",
"when": "editorTextFocus && !editorReadonly && !inCompositeEditor"
}
Benoit de Chezelles commented
Kinda related:
- Submodes proposal: neovim/neovim#16313 which suggests the creation of namespaced keybindings, to be applied to buffer / window / global
- Emacs major/minor modes: https://www.gnu.org/software/emacs/manual/html_node/emacs/Modes.html Which allow opt-in multiple minor modes (global/local) and one active major mode for the current file.