Same filename in this branch
  1. 10 core/modules/system/templates/feed-icon.html.twig
  2. 10 core/themes/olivero/templates/misc/feed-icon.html.twig
  3. 10 core/themes/stable9/templates/media-library/feed-icon.html.twig
Same filename and directory in other branches
  1. 8.9.x core/modules/system/templates/feed-icon.html.twig
  2. 9 core/modules/system/templates/feed-icon.html.twig

Default theme implementation for a feed icon.

Available variables:

  • url: An internal system path or a fully qualified external URL of the feed.
  • title: Title of the feed for describing the feed on the subscribe link.
  • attributes: Remaining HTML attributes for the feed link.
    • title: A descriptive title of the feed link.
    • class: HTML classes to be applied to the feed link.
1 theme call to feed-icon.html.twig
AddFeedTest::testFeedIconEscaping in core/modules/system/tests/src/Kernel/Common/AddFeedTest.php
Checks that special characters are correctly escaped.

File

core/modules/system/templates/feed-icon.html.twig
View source
  1. {#
  2. /**
  3. * @file
  4. * Default theme implementation for a feed icon.
  5. *
  6. * Available variables:
  7. * - url: An internal system path or a fully qualified external URL of the feed.
  8. * - title: Title of the feed for describing the feed on the subscribe link.
  9. * - attributes: Remaining HTML attributes for the feed link.
  10. * - title: A descriptive title of the feed link.
  11. * - class: HTML classes to be applied to the feed link.
  12. *
  13. * @ingroup themeable
  14. */
  15. #}
  16. <a href="{{ url }}"{{ attributes.addClass('feed-icon') }}>
  17. {{ 'Subscribe to @title'|t({'@title': title}) }}
  18. </a>

Related topics