AbstractTag
abstract class AbstractTag implements TagInterface (View source)
Provides immutable attribute-based metadata tags while escaping their name and content.
Custom subclasses must remain readonly to preserve the tag's fixed key and content.
Traits
Methods
__construct(string $key, string|null $content)
Initializes the tag's attribute value and optional content.
template()
string
render()
Renders the concrete tag template or suppresses it for empty content.
string
Details
__construct
__construct(string $key, string|null $content)
Initializes the tag's attribute value and optional content.
template
abstract protected string
template()
No description
render
string
render()
Renders the concrete tag template or suppresses it for empty content.