DrupalCon Los Angeles 2015: Drupal 8 Theming with Love

Drupal Association · 4K views · 2015 · 52:24

Open on YouTube

Web developmenttalkdated

Why Drupal Answers Stack Exchange recommends it

Drupal Stack Exchange answerers and commenters point people to it for practical Twig theming techniques, such as removing blocks or customizing field and link markup in Drupal 8 templates.

Recommended by 1 people across 1 different months, 2015 to 2018.

What it is

A DrupalCon Los Angeles 2015 session by Morten (mortendk) introducing Drupal 8 theming from a front-end developer's point of view. It covers the theme structure, the Twig template system, Classy and Stark, base themes, debugging markup, and CSS and JS organization.

What people said

Recommends rameshrasaiyan · 2015-11 · Drupal Answers Stack Exchange · on “How do I unset a block?”

Hi @Berdir, I did something like this `{{ page.header|without('THEME_breadcrumbs')}}` to remove the breadcrumbs and added the breadcrumbs wherever I needed by adding this `{{ page.header.THEME_breadcrumbs }}` in the `page.html.twig` as per the Mortendk's video [this video] . Is this the right approach? Please advise.

Cites Sebastian Nordstrand Nørgaard · 2017-03 · Drupal Answers Stack Exchange · on “Customize the HTML of a link field from a custom theme”

Try this: {% for item in items %} <a href="{{ item.content['#url'] }}" class="btn-circle btn-circle--blue js-open-modal"> {{ item.content.text }} </a> {% endfor %} Found it in a video from 2015, where MortenDK is showing off It's about 25 min. in DrupalCon Los Angeles 2015: Drupal 8 Theming with Love [this video]

Cites kaicyee · 2018-07 · Drupal Answers Stack Exchange · on “Customize the HTML of a link field from a custom theme”

Spent 2 days on this similar problem. Sebastian, you almost had it. Twig snippet should look more like this: {% for item in items %} <a href="{{ item.content['#url'] }}" class="btn-circle btn-circle--blue js-open-modal"> {{ item.content.['#title'] }} </a> {% endfor %} ['#title'] - is really important to place the text in the a href tag Definitely MortenDK was very helpful: [this video]