Twig is a GPL Cart module that integrates TWIG template engine into your GPL Cart site. Essentially it tries to parse every template file with .twig extension
Custom TWIG functions added by this module:
- error()
- text()
- access()
- url()
- date()
- attributes()
- config()
- configTheme()
- teaser()
- filter()
- truncate()
- path()
See \gplcart\core\Controller
for corresponding methods
Installation
This module requires 3-d party library which should be downloaded separately. You have to use Composer to download all the dependencies.
- From your web root directory:
composer require gplcart/twig
. If the module was downloaded and placed intosystem/modules
manually, runcomposer update
to make sure that all 3-d party files are presented in thevendor
directory. - Go to
admin/module/list
end enable the module - Optionally adjust settings on
admin/module/settings/twig