$blocks->prepend()
Prepends an element to the data array
$blocks->prepend(string|Kirby\Cms\Block ...$args): Kirby\Cms\Blocks
Parameters
Name | Type | Default |
---|---|---|
...$args | string orKirby\Cms\Block |
no default value |
Return type
This method modifies the existing $
object it is applied to and returns it again.
Parent class
Kirby\Cms\Blocks
inherited from Kirby\Cms\Collection
Examples
$collection->prepend($object);
$collection->prepend('key', $object);