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

Breadcrumb

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

function EntityReference::render

Same name in this branch
  1. 11.1.x core/modules/views/src/Plugin/views/style/EntityReference.php \Drupal\views\Plugin\views\style\EntityReference::render()

Builds the view result as a renderable array.

Return value

array Renderable array or empty array.

Overrides DisplayPluginBase::render

File

core/modules/views/src/Plugin/views/display/EntityReference.php, line 138

Class

EntityReference
The plugin that handles an EntityReference display.

Namespace

Drupal\views\Plugin\views\display

Code

public function render() {
    if (!empty($this->view->result) && $this->view->style_plugin
        ->evenEmpty()) {
        return $this->view->style_plugin
            ->render($this->view->result);
    }
    return [];
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal