Same name and namespace in other branches
  1. 8.9.x core/lib/Drupal/Core/Render/Element/HtmlTag.php \Drupal\Core\Render\Element\HtmlTag::voidElements
  2. 9 core/lib/Drupal/Core/Render/Element/HtmlTag.php \Drupal\Core\Render\Element\HtmlTag::voidElements

Void elements do not contain values or closing tags.

See also

http://www.w3.org/TR/html5/syntax.html#syntax-start-tag

http://www.w3.org/TR/html5/syntax.html#void-elements

File

core/lib/Drupal/Core/Render/Element/HtmlTag.php, line 41

Class

HtmlTag

Namespace

Drupal\Core\Render\Element

Code

protected static $voidElements = [
  'area',
  'base',
  'br',
  'col',
  'embed',
  'hr',
  'img',
  'input',
  'keygen',
  'link',
  'meta',
  'param',
  'source',
  'track',
  'wbr',
  'rect',
  'circle',
  'polygon',
  'ellipse',
  'stop',
  'use',
  'path',
];