$files->count()

Returns the number of files in the collection

  • return (integer)

Example

echo $page->files()->count();

echo $page->images()->count();

echo $page->documents()->count();

echo $page->files()->filterBy('extension', 'pdf')->count();