Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. StylePluginBase.php

Views style plugins

Plugins that control how the collection of results is rendered in a view.

Style plugins control how a view is displayed. For the most part, they are object wrappers around theme templates. Examples of styles include HTML lists, tables, full or teaser content views, etc.

Many (but not all) style plugins have an optional row plugin, which displays a single record. Not all style plugins use row plugins, so it is up to the style plugin to set this up and call the row plugin. See the Views row plugins topic for more information.

Style plugins extend \Drupal\views\Plugin\views\style\StylePluginBase. They must be annotated with \Drupal\views\Annotation\ViewsStyle annotation, and they must be in namespace directory Plugin\views\style.

See also

Plugin API

Parent topics

Views plugins
Overview of views plugins

File

core/modules/views/src/Plugin/views/style/StylePluginBase.php, line 14

Classes

Title Sort descending File name Summary
DefaultStyle core/modules/views/src/Plugin/views/style/DefaultStyle.php Unformatted style plugin to render rows.
DefaultSummary core/modules/views/src/Plugin/views/style/DefaultSummary.php The default style plugin for summaries.
EntityReference core/modules/views/src/Plugin/views/style/EntityReference.php EntityReference style plugin.
Grid core/modules/views/src/Plugin/views/style/Grid.php Style plugin to render each item in a grid cell.
GridResponsive core/modules/views/src/Plugin/views/style/GridResponsive.php Style plugin to render each item in a responsive grid cell.
HtmlList core/modules/views/src/Plugin/views/style/HtmlList.php Style plugin to render each item in an ordered or unordered list.
Mapping core/modules/views/src/Plugin/views/style/Mapping.php Allows fields to be mapped to specific use cases.
Opml core/modules/views/src/Plugin/views/style/Opml.php Default style plugin to render an OPML feed.
Rss core/modules/views/src/Plugin/views/style/Rss.php Default style plugin to render an RSS feed.
Serializer core/modules/rest/src/Plugin/views/style/Serializer.php The style plugin for serialized output formats.
StylePluginBase core/modules/views/src/Plugin/views/style/StylePluginBase.php Base class for views style plugins.
Table core/modules/views/src/Plugin/views/style/Table.php Style plugin to render each item as a row in a table.
UnformattedSummary core/modules/views/src/Plugin/views/style/UnformattedSummary.php The default style plugin for summaries.
ViewsStyle core/modules/views/src/Attribute/ViewsStyle.php Defines a views style plugins type attribute for plugin discovery.
ViewsStyle core/modules/views/src/Annotation/ViewsStyle.php Defines a Plugin annotation object for views style plugins.
RSS feed
Powered by Drupal