Automatically insert a matching brace in Vim

前端 未结 18 2330
醉梦人生
醉梦人生 2020-12-13 05:23

I spend way too much time fumbling around because Vim doesn\'t handle closing braces like most IDEs do. Here\'s what I want to happen:

Type this:

         


        
18条回答
  •  时光说笑
    2020-12-13 06:09

    Using AutoClose with the following works correctly.

    inoremap { {}O
    

    This is true for my system at least (Unix terminal on Mac OS X).

提交回复
热议问题