Another Twig Improvements
- by Ondrej Brejla
Hi all! We are here again to intorduce you some of our new NetBeans 7.3 features. Today we'll show you some another Twig improvements. So let's start!
Code Templates
First feature is about Code Templates. We added some basic templates to improve your Editor experience. You will be really fast with it!
If someone don't know what Code Templates are, they are piece of code (snippet) which is inserted into editor after typing its abbreviation and pressing Tab key (or another one which you define in Tools -> Options -> Editor -> Code Templates -> Expand Template on) to epxand it.
All default Twig Code Templates can be found in Tools -> Options -> Editor -> Code Templates -> Twig Markup. You can add your custom templates there as well.
Note: Twig Markup code templates have to be expanded inside Twig delimiters (i.e. { and }). If you try to expand them outside of delimiters, it will not work, because then you are in HTML context. If you want to add a template which will contain Twig delimiter too, you have to add it directly into Tools -> Options -> Editor -> Code Templates -> HTML/XHTML. Don't add them into Twig File, it will not work.
Interpolation Coloring
The second, minor, feature is, that we know how to colorize Twig Interpolation. It's a small feature, but usefull :-)
And that's all for today and as usual, please test it and if you find something strange, don't hesitate to file a new issue (product php, component Twig). Thanks a lot!