function ResponsiveImage::getInfo

Same name in other branches
  1. 9 core/modules/responsive_image/src/Element/ResponsiveImage.php \Drupal\responsive_image\Element\ResponsiveImage::getInfo()
  2. 10 core/modules/responsive_image/src/Element/ResponsiveImage.php \Drupal\responsive_image\Element\ResponsiveImage::getInfo()
  3. 11.x core/modules/responsive_image/src/Element/ResponsiveImage.php \Drupal\responsive_image\Element\ResponsiveImage::getInfo()

Overrides ElementInterface::getInfo

File

core/modules/responsive_image/src/Element/ResponsiveImage.php, line 17

Class

ResponsiveImage
Provides a responsive image element.

Namespace

Drupal\responsive_image\Element

Code

public function getInfo() {
    return [
        '#theme' => 'responsive_image',
        '#attached' => [
            'library' => [
                'core/picturefill',
            ],
        ],
    ];
}

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