$files->first()

Returns the first file in the collection

  • return ($file)

Example

<?= $page->files()->first()->filename() ?>

Is something missing or incorrect? Edit this page on Github…