It is also possible to insert erb tags in INSERT mode (using rails.vim and surround.vim plugins):
- Press Ctrl + s and = afterwards to insert
<%= %>block - Press Ctrl + s and - afterwards to insert
<% -%>block - Press Ctrl + s and # afterwards to insert
<%# %>block