daveosborne / brackets-vimderbar

Adding vim functionality to Adobe's Brackets
MIT License
149 stars 15 forks source link

Esc remapping #54

Open barrio opened 6 years ago

barrio commented 6 years ago

I want to do inoremap jk <Esc>

I followed the docs about user custom key remappings and inserted the following in brackets.json:

"vimderbar.mappings": [
        {"keys": "jk", "toKeys": "Esc",  "mode": "insert"}
    ]

When I press jk in insert mode, jk is deleted but vimderbar still stays in insert mode. Do I miss something here or is this a bug?

casecadet commented 5 years ago

Just set this up, in case anyone could still use an answer-- try \ with brackets included:

"vimderbar.mappings": [{ "keys": "jk", "toKeys": "<Esc>", "mode": "insert" }]

I also map "kj" to the same thing, so I can just hit both keys simultaneously to exit.