Snippet::factory()
Returns either an open snippet capturing slots or the template string for self-enclosed snippets
Snippet::factory(array|string|null $name, array $data = [ ], bool $slots = false): Kirby\Template\Snippet|string
Parameters
Name | Type | Default |
---|---|---|
$name | array orstring ornull |
no default value |
$data | array |
[ ]
|
$slots | bool |
false
|
Return types
Kirby\Template\Snippet
orstring