On our D8 site we have a content type with a webform reference field field_reference_webform
.
We then created a view with a custom views display style plugin for above content type that uses the webform reference field field_reference_webform
.
What we want to achieve is to print the webform field in our custom view display style directly via views-view-our-display-plugin.html.twig.
The contents of our Webform reference field, however, wouldn't print. We tried to print it with below code:
{% if rows|length %}
{% for row in rows %}
{{ row._entity.field_reference_webform }}
{% endfor %}
{% endif %}
Instead we get the following error:
Object of type Drupal\webform\Plugin\Field\FieldType\WebformEntityReferenceFieldItemList cannot be printed
We cannot figure out what we got wrong.
We are on Drupal 8.6.2 using Webform 8.x-5.0-rc22