function BooleanItemNormalizer::getSupportedTypes
Overrides FieldItemNormalizer::getSupportedTypes
File
-
core/
modules/ serialization/ tests/ modules/ test_fieldtype_boolean_emoji_normalizer/ src/ Normalizer/ BooleanItemNormalizer.php, line 44
Class
- BooleanItemNormalizer
- Normalizes boolean fields weirdly: renders them as 👍 (TRUE) or 👎 (FALSE).
Namespace
Drupal\test_fieldtype_boolean_emoji_normalizer\NormalizerCode
public function getSupportedTypes(?string $format) : array {
return [
BooleanItem::class => TRUE,
];
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.