$file->name()

Returns the name of the file without extension

  • return (string)

Example

echo $page->file('my-image.jpg')->name();
// my-image

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