ComponentSlot
class ComponentSlot implements Htmlable, Stringable
Properties
| ComponentAttributeBag | $attributes | The slot attribute bag. |
Methods
__construct(string $contents = '', array $attributes = [])
Create a new slot instance.
withAttributes(array $attributes)
Set the extra attributes that the slot should make available.
string
toHtml()
Get the slot's HTML string.
bool
isEmpty()
Determine if the slot is empty.
bool
isNotEmpty()
Determine if the slot is not empty.
bool
hasActualContent(callable|string|null $callable = null)
Determine if the slot has non-comment content.
string
__toString()
Get the slot's HTML string.
Details
at line 21
__construct(string $contents = '', array $attributes = [])
Create a new slot instance.
at line 31
ComponentSlot
withAttributes(array $attributes)
Set the extra attributes that the slot should make available.
at line 41
string
toHtml()
Get the slot's HTML string.
at line 49
bool
isEmpty()
Determine if the slot is empty.
at line 57
bool
isNotEmpty()
Determine if the slot is not empty.
at line 65
bool
hasActualContent(callable|string|null $callable = null)
Determine if the slot has non-comment content.
at line 81
string
__toString()
Get the slot's HTML string.