$field->value()
Returns the field content. If a new value is passed, the modified field will be returned. Otherwise it will return the field value.
$field->value(Closure|string|null $value = null): mixed
Parameters
Name | Type | Default |
---|---|---|
$value | Closure orstring ornull |
null
|
Return type
mixed
This method modifies the existing $field
object it is applied to and returns it again.
Examples
<?= $page->text()->value() ?>