$user->username()
Returns the username which is the given name or the email as a fallback
$user->username(): string|null
Return type
string
|null
Parent class
Example
<?= $kirby->user('bastian@example.com')->username() ?>
Returns the username which is the given name or the email as a fallback
$user->username(): string|null
string
|null
<?= $kirby->user('bastian@example.com')->username() ?>