How do I insert ERB-tags with Vim?

后端 未结 3 711
自闭症患者
自闭症患者 2021-01-30 00:57

How do I insert <% %> in Vim? I have rails.vim.

3条回答
  •  时光说笑
    2021-01-30 01:34

    It is also possible to insert erb tags in INSERT mode (using rails.vim and surround.vim plugins):

    1. Press Ctrl + s and = afterwards to insert <%= %> block
    2. Press Ctrl + s and - afterwards to insert <% -%> block
    3. Press Ctrl + s and # afterwards to insert <%# %> block

提交回复
热议问题