Filament v2 property null when searching
I have a filament table from a livewire component.
Witch i want to make it be dynamic to work with different logic per table
I have a
mount()
method that looks like:
and my methods look like this
But when i go to a next page or try to use the search i get that the tableProperty
is null
if i add the initialize of the tableProperty
in each method everything is normal
But this does not look good in my opinion.
So what must i do to escape this repeating and initialize the tableProperty
just once ?Solution:Jump to solution
To escape this repeating of code i added the
hydrate
hook in the livewire component
This worked very well
```php
public function mount()...1 Reply
Solution
To escape this repeating of code i added the
hydrate
hook in the livewire component
This worked very well