<< All Posts
How to add syntax highlight for .twig on VIM?


In this simple post, I’ll teach you how to add syntax highlight for .twig on VIM. If you are working with a PHP Framework like symfony2 + vim, you probably are getting boring using .twig without any syntax highlighter right? So, follow these steps and get your twig full of colors easy:

1) Download both jinja.vim and htmljinja.vim for this folder ~/.vim/syntax

2) After that, add this on the bottom of your .vimrc file:

au BufRead,BufNewFile *.twig set filetype=htmljinj

3) Restart your vim and you will see the .twig template much better!



<< All Posts

rodolfo.io

🇧🇷 🇨🇦
Runs on OpenBSD 🐡