Snippet::load()
Loads the code of the given snippet
Snippet::load(string|null $file = null, array $data = [], Slots|null $slots = null): string
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
| $file | stringornull |
null
|
Path to the snippet file |
| $data | array |
[]
|
Data available inside the snippet |
| $slots | Kirby\Template\Slotsornull |
null
|
Slots available inside the snippet |
Return type
string