I have a custom block type with a link field and an image field. I want to combine those fields to wrap the image in the link.
I created a Display Suite Twig field. What do I use to show the image?
Ideally the image as rendered in Manage display, but as long as I can show the image with a certain image style, I'd be very happy.
This is what I have already tried.
{{ file_url(node.field_career_highlight_image.entity.uri.value) }}
{{ file_url(content.field_career_highlight_image['#items'].entity.uri.value) }}
{{ file_url(block_content.field_career_highlight_image.0['#item'].entity.uri.value) }}
{{ file_url(node.field_career_highlight_image['#items'].entity.uri.value) }}
{{ block_content.field_career_highlight_image.alt }} - shows alt, just experimenting, so wondering why this didn't work for the image
{{ content.field_career_highlight_image }}
{{ block_content.field_career_highlight_image }} - white screen
{{ block_content.field_career_highlight_image.0 }}
{{ block_content.field_career_highlight_image.0.value }}
{{ block_content.field_career_highlight_image[0] }}
{{ block_content['#block_content'].field_career_highlight_image.value }}
{{ content['#block_content'].field_career_highlight_image.value }}
{{ content['#block_content'].field_career_highlight_image }}