I'm having a bit of a hard time with Drupal 8.
I've created a custom theme and am trying to override twig files. I've got debugging enabled so I know which files to copy to my template directory. However, when I copy a twig template it outputs nothing.
For example, I'm trying to wrap the site title in an
H1 element. The core template file used in this case is /core/themes/stable/templates/block/block--system-branding-block.html.twig. If I add the
H1 element in that file the header is inside a
H1 element, but when I copy the twig file to my template directory the whole header is gone.
I can see in the source code that the file was found:
<!-- BEGIN OUTPUT from 'themes/mytheme/block--system-branding-block.html.twig' --> <!-- END OUTPUT from 'themes/mytheme/block--system-branding-block.html.twig' -->
The documentation suggests that copying the relevant twig file is all that's needed but maybe I'm missing something? And if this should work, how can I debug this issue (the Apache error log doesn't report any errors).