本気のメモ
HTMLテンプレート
- ベーステンプレート:html.html.twig
- 位置:core/modules/system/templates/html.html.twig
- APIドキュメント:https://api.drupal.org/api/drupal/core!modules!system!templates!html.html.twig/8
ページテンプレート
- ベーステンプレート:page--[front|internal|path].html.twig
- 位置:core/modules/system/templates/page.html.twig
- APIドキュメント:https://api.drupal.org/api/drupal/core!modules!system!templates!page.html.twig/8
リージョンテンプレート
可能なリージョン名はテーマ.info.ymlファイルによって決まる
- ベーステンプレート:region--[region].html.twig
- 位置:core/modules/system/templates/region.html.twig
- APIドキュメント:https://api.drupal.org/api/drupal/core!modules!system!templates!region.html.twig/8
ブロックテンプレート
moduleはモジュールの名前で管理画面上で言うシステム内部名称、deltaはモジュールによってブロックに割り当てられた内部ID
- ベーステンプレート:block--[module|-delta].html.twig
- 位置:core/modules/block/templates/block.html.twig
- APIドキュメント:https://api.drupal.org/api/drupal/core!modules!block!templates!block.html.twig/8
ノードテンプレート
- ベーステンプレート:node--[type|nodeid]--[viewmode].html.twig
- 位置:core/modules/node/templates/block.html.twig
- APIドキュメント:https://api.drupal.org/api/drupal/core!modules!node!templates!node.html.twig/8
タクソノミータームテンプレート
- ベーステンプレート:taxonomy-term--[vocablary-machine-name|tid].html.twig
- 位置:core/modules/taxonomy/templates/taxonomy-term.html.twig
- APIドキュメント:https://api.drupal.org/api/drupal/core!themes!stable!templates!content!taxonomy-term.html.twig/8
フィールドテンプレート
- ベーステンプレート:field--[type|name[--content-type][content-type]].html.twig
- 位置:core/modules/system/templates/field.html.twig
- APIドキュメント:https://api.drupal.org/api/drupal/core!themes!stable!templates!field!field.html.twig/8