Skip to content

Kirby 5.2.0

$slots->count()

Counts the number of defined slots

$slots->count(): int

Return type

int

This method modifies the existing $slots object it is applied to and returns it again.

Parent class

Kirby\Template\Slots