Twig

Drupal 8 - template changes

Submitted by superadmin on Sun, 12/13/2015 - 14:24

By default templates are compiled and stored in memory. Any template changes will not be reflected until the cache is rebuilt(drush rebuid) which is not workable in a development environment.

To have the template files recompiled when they are changed, debugging must be enabled in the twig engine. This can be done either using Drupal console or sites/defualt/services.yml. If you don't have services.yml you can create it by copying sites/defualt/default.services.yml to sites/defualt/services.yml and changing the following: