After trawling though Volt, Livewire and Folio docs I found what i thought was the answer to this but none of these seem to work!
So tried using:
public function rendering(View $view): void
{
$view->title('Login');
}
But throws an error about not being able to find the $title variable.
then i moved onto:
use Livewire\Attributes\Title;
use Livewire\Component;
#[Title('Login')]
new class extends Component...
That throws an error about unexpected new.
so moved onto:
use Livewire\Attributes\Title;
use Livewire\Component;
new #[Title('Login')] class extends Component...
That again throws an error about not being able to find the $title variable.
So I moved onto using:
use function Livewire\Volt\{title};
...
title('Login');
Again throws an error about not being able to find the $title variable.
I reset the caches each time I am stumped to what is going on. Has anyone had success with any of these or a way to add the page title?
After trawling though Volt, Livewire and Folio docs I found what i thought was the answer to this but none of these seem to work!
So tried using:
But throws an error about not being able to find the $title variable.
then i moved onto:
That throws an error about unexpected new.
so moved onto:
That again throws an error about not being able to find the $title variable.
So I moved onto using:
Again throws an error about not being able to find the $title variable.
I reset the caches each time I am stumped to what is going on. Has anyone had success with any of these or a way to add the page title?