BlankFormatter.php
Namespace
Drupal\layout_builder_test\Plugin\Field\FieldFormatterFile
-
core/
modules/ layout_builder/ tests/ modules/ layout_builder_test/ src/ Plugin/ Field/ FieldFormatter/ BlankFormatter.php
View source
<?php
declare (strict_types=1);
namespace Drupal\layout_builder_test\Plugin\Field\FieldFormatter;
use Drupal\Core\Field\Attribute\FieldFormatter;
use Drupal\Core\Field\FieldItemListInterface;
use Drupal\Core\Field\FormatterBase;
use Drupal\Core\StringTranslation\TranslatableMarkup;
/**
* A blank field formatter.
*/
final class BlankFormatter extends FormatterBase {
/**
* {@inheritdoc}
*/
public function viewElements(FieldItemListInterface $items, $langcode) : array {
return [];
}
}
Classes
| Title | Deprecated | Summary |
|---|---|---|
| BlankFormatter | A blank field formatter. |
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.