RenderableInterface.php

Same filename and directory in other branches
  1. 9 core/lib/Drupal/Core/Render/RenderableInterface.php
  2. 8.9.x core/lib/Drupal/Core/Render/RenderableInterface.php
  3. 10 core/lib/Drupal/Core/Render/RenderableInterface.php

Namespace

Drupal\Core\Render

File

core/lib/Drupal/Core/Render/RenderableInterface.php

View source
<?php

namespace Drupal\Core\Render;


/**
 * Defines an object which can be rendered by the Render API.
 */
interface RenderableInterface {
    
    /**
     * Returns a render array representation of the object.
     *
     * @return mixed[]
     *   A render array.
     */
    public function toRenderable();

}

Interfaces

Title Deprecated Summary
RenderableInterface Defines an object which can be rendered by the Render API.

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.