Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Tomas Votruba:
New in Statie 4.5: Twig Support
Jul 16, 2018 @ 15:46:21

Tomas Votruba has a new post to his site about an update that's been made on Statie, a static site generation tool, to support Twig templates natively.

Statie supports YAML and Symfony Dependency Injection for some time. But you wanted more! You wanted Twig. Sculpin and all the other PHP generators have it.

So there you go! Enjoy.

He shares the three steps needed to set up a sample Twig template and have it rendered as easily as the normal Statie templates:

  1. Prepare Layout _layouts/default.twig
  2. Create Template contact.twig
  3. Enable Twig

Template contents and configuration change examples are included as well as instructions on how to update to this latest (v5.4) version. He includes tips on the naming and locations of the template files as well as a mention of his package to help translate from Latte to Twig templates.

tagged: statie twig support native tutorial latte template

Link: https://www.tomasvotruba.cz/blog/2018/07/16/new-in-statie-45-twig-support/


Trending Topics: