Created
May 13, 2022 19:06
-
-
Save paboden/dd2ad3a9c97e58dec6e127b1f93964f0 to your computer and use it in GitHub Desktop.
Drupal 8/9: Get a field in a paragraph entity in a paragraph entity inside of a node entity
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {% for item in node.field_content %} | |
| <h3>{{item.entity.field_heading.value }}</h3> | |
| <ul> | |
| {% for s in item.entity.field_section_content %} | |
| {% set sub = s.entity.field_sub_heading.value %} | |
| {% set icon = s.entity.field_media_type.value %} | |
| <li class="{{ icon }}"> {{ sub }}</li> | |
| {% endfor %} | |
| </ul> | |
| {% endfor %} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment