About Template Engine Twig

This module adds the Twig template engine to the TemplateEngineFactory

Category 1Development Tools
Modules that have more to do with assisting development of a site rather than managing its content.
Category 2Markup Generation
Markup modules that are called upon to generate or parse markup (like HTML). Markup modules are most often used on the front-end of a site (rather than admin).
Category 3Other Modules
Modules that have a unique purpose not covered by existing categories.
Release StateStable
Should be safe for use in production environments. *
Module Version1.1.0
Class NameTemplateEngineTwig
Compatibility2.3, 2.4, 2.5, 2.6, 2.7, 3.0
Date AddedJuly 3, 2014
Last UpdatedMarch 19, 2018
Recommended ByNew recommendations may take up to 1 day to appear.


This module's files should be placed in /site/modules/TemplateEngineTwig/
How to install or uninstall modules



ProcessWire module adding Twig templates to the TemplateEngineFactory


Install the module just like any other ProcessWire module. Check out the following guide: http://modules.processwire.com/install-uninstall/

This module requires TemplateEngineFactory: https://github.com/wanze/TemplateEngineFactory

After installing, don't forget to enable Twig as engine in the TemplateEngineFactory module's settings.


  • Path to templates Path to folder where you want to store your Twig template files.
  • Template files suffix The suffix of the template files, default is html.
  • Import ProcessWire API variables in Twig template If checked, any API variable is accessible inside the Twig templates, for example {{ page }} refers to the current page.
  • Auto reload templates (recompile) If enabled, templates are recompiled whenever the source code changes.
  • Auto escape variables If enabled, templates will auto-escape variables. If you use ProcessWire's textformatter to escape variables, do not enable this feature.


No comments yet. Be the first to post!

Post a Comment

Your e-mail is kept confidential and not included with your comment. Website is optional.