Drupal is a registered trademark of Dries Buytaert
Protected Pages 3.0.0 Major update available for module protected_pages (3.0.0). Commerce Core 3.3.8 Minor update available for module commerce (3.3.8). Search API HTML Element Filter 1.0.7 Minor update available for module search_api_html_element_filter (1.0.7). Layout Builder Reorder 2.0.1 Minor update available for module layout_builder_reorder (2.0.1). Ban 1.1.0 Minor update available for module ban (1.1.0). Field Formatter Range 2.0.0 Major update available for module field_formatter_range (2.0.0). Field Formatter Range 8.x-1.8 Minor update available for module field_formatter_range (8.x-1.8). Varbase Media Header 9.2.1 Minor update available for module varbase_media_header (9.2.1). Search API Solr 4.3.11 Module search_api_solr updated after 14 months of inactivity (4.3.11). Provus Mega Menu Module provus_mega_menu crossed 1,000 active installs.

This module allows other modules to provide Views templates, which are reusable collections of templates and variable definitions that define a specific presentation style. These templates can be programmatically created or built from YAML files and can be overridden based on various view and display configurations.

This module is intended to be used by other modules to offer Views templates.
Modules can implement ViewsTemplateBuilder plugins to provide Views templates.

Extend the ViewsBuilderBase class to make View template programmatically

Extend the ViewsDuplicateBuilderBase class to make a View Template from a *.yml Views Template file.

Views Templates should put in the 'views_templates' in the root directory
of the module.

Creates the views templates functionality which was removed in D8 views. A view is effectively a collection of templates and/or variable definitions that can be passed around as a self-contained unit. This then represents a particular interface or presentation style for other objects or items of data. You can use views to implement custom "skins" for an application or content set. You can use them to help simplify the presentation of common objects or data types. You can even use them to automate the presentation of complex data structures such as that generated in an XML::DOM tree or similar. You let an iterator do the walking, and the view does the talking (or in this case, the presenting). Voila - you have to view independent, structure shy traversal using templates.

Views templates can be overridden with a variety of names, using the view, the display ID of the view, the display type of the view, or some combination thereof.

For each view, there will be a minimum of two templates used. The first is used for all views: views-view.html.twig.

The second template is determined by the style selected for the view. Note that certain aspects of the view can also change which style is used; for example, arguments that provide a summary view might change the style to one of the special summary styles.

The default style for all views is views-view-unformatted.html.twig

Many styles will then farm out the actual display of each row to a row style; the default row style is views-view-fields.html.twig.

Activity

Total releases
1
First release
Jan 2026
Latest release
5 months ago
Releases (12 mo)
1 ▲ from 0
Maintenance
Active

Releases

Version Type Release date
8.x-1.7 Stable Jan 30, 2026