function Rss::preRender
Allow the style to do stuff before each row is rendered.
Parameters
$result: The full array of results from the query.
Overrides RowPluginBase::preRender
File
- 
              core/
modules/ comment/ src/ Plugin/ views/ row/ Rss.php, line 51  
Class
- Rss
 - Plugin which formats the comments as RSS items.
 
Namespace
Drupal\comment\Plugin\views\rowCode
public function preRender($result) {
  $cids = [];
  foreach ($result as $row) {
    $cids[] = $row->cid;
  }
  $this->comments = $this->entityTypeManager
    ->getStorage('comment')
    ->loadMultiple($cids);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.