public function RecentCommentsBlock::build

Builds and returns the renderable array for this block plugin.

Return value

array A renderable array representing the content of the block.

Overrides BlockPluginInterface::build

See also

\Drupal\block\BlockRenderController

File

drupal/core/modules/comment/lib/Drupal/comment/Plugin/Block/RecentCommentsBlock.php, line 64
Contains \Drupal\comment\Plugin\Block\RecentCommentsBlock.

Class

RecentCommentsBlock
Provides a 'Recent comments' block.

Namespace

Drupal\comment\Plugin\Block

Code

public function build() {
  return array(
    '#theme' => 'comment_block',
    '#number' => $this->configuration['block_count'],
  );
}