$api->hasData()
Checks if injected data exists for the given key
$api->hasData(string $key): bool
Parameters
| Name | Type | Default |
|---|---|---|
| $keyrequired | string |
no default value |
Return type
bool
This method modifies the existing $api object it is applied to and returns it again.
Parent class
Kirby\Cms\Api
inherited from Kirby\Api\Api