Archived video

This video is archived and won't be updated. We're keeping it online for now as a courtesy.

Alternate resources: 

Twig: Templates in Symfony 3

Video loading...

Transcript language code: 

Join Drupalize.Me to watch this video

Join today and gain instant access to our entire video library.

Log in Sign up
  • 0:08
    Unless you're building a pure API,
  • 0:10
    Twig is your new best friend.
  • 0:12
    Rarely do you find a library that's this much fun to use.
  • 0:16
    It's also really easy, so let me just give you a quick intro.
  • 0:20
    Twig has 2 syntaxes.
  • 0:22
    "{{ }}," which is the Say Something tag
  • 0:27
    and "{% %}," which is the Do Something tag.
  • 0:34
    If you're printing something, you always write {{
  • 0:37
    then a variable name, a string, or any expression.
  • 0:40
    Twig actually looks a lot like JavaScript.

Twig: Templates in Symfony 3


In this lesson, you'll get a crash course in Twig. Covered here are the "say something" syntax, the "do something" syntax and for loops. For broader coverage of Twig and the amazing things you can do with it, head over to the Twig Templating series.

Log in or sign up to download companion files.
Additional resources: