ralphjsmit
ralphjsmit
Explore posts from servers
FFilament
Created by charlie on 1/19/2025 in #❓┊help
How to use Alpine in Filament?
Then you dont need a div
26 replies
FFilament
Created by charlie on 1/19/2025 in #❓┊help
How to use Alpine in Filament?
26 replies
FFilament
Created by charlie on 1/19/2025 in #❓┊help
How to use Alpine in Filament?
It depends on what you want to do with it again after you got access to the values
26 replies
FFilament
Created by charlie on 1/19/2025 in #❓┊help
How to use Alpine in Filament?
You need to entangle it somehow
26 replies
FFilament
Created by charlie on 1/19/2025 in #❓┊help
How to use Alpine in Filament?
Yeah for example
26 replies
FFilament
Created by charlie on 1/19/2025 in #❓┊help
How to use Alpine in Filament?
You should try, but it might even work without the .live and without a server request
26 replies
FFilament
Created by charlie on 1/19/2025 in #❓┊help
How to use Alpine in Filament?
And that also goes two-ways, if your TextInput or ColorPicker state updates, then the $my_text_input gets updated, Livewire/Alpine knows that it is entangled as well with your custom x-data and then it gets updated both
26 replies
FFilament
Created by charlie on 1/19/2025 in #❓┊help
How to use Alpine in Filament?
If you update the my_text_input, then Alpine is entangled with the $my_text_input on the server. That means that if you update that property in Alpine, the $my_text_input property also gets updated on the server. In turn, your TextInput or ColorPicker is also entangled with $my_text_input, so if $my_text_input updates, your TextInput or ColorPicker also updates.
26 replies
FFilament
Created by charlie on 1/19/2025 in #❓┊help
How to use Alpine in Filament?
Yes, with what I shared you can
26 replies
FFilament
Created by charlie on 1/19/2025 in #❓┊help
How to use Alpine in Filament?
(You are also missing a mount() method that includes a $this->form->fill() but perhaps you just omitted that for simplicity)
26 replies
FFilament
Created by charlie on 1/19/2025 in #❓┊help
How to use Alpine in Filament?
Also, I would personally not recommend creating individual properties for all of them, but just to add public ?array $data = null and then $form->statePath('data'), then you will only have just one property on your Livewire. And then in Alpine you do state: $wire.entangle('state').live.
26 replies
FFilament
Created by charlie on 1/19/2025 in #❓┊help
How to use Alpine in Filament?
Ah! This works just the same as sharing any other Livewire state with JS, with the only difference that the LW property is also written/read by Filament in addition to your own reads/writes. Try
<div
x-data="{
my_text_input: $wire.entangle('my_text_input').live,
another_text_input: $wire.entangle('another_text_input').live
}
x-init="..."
>
</div>
<div
x-data="{
my_text_input: $wire.entangle('my_text_input').live,
another_text_input: $wire.entangle('another_text_input').live
}
x-init="..."
>
</div>
See https://livewire.laravel.com/docs/alpine#sharing-state-using-wireentangle
26 replies
FFilament
Created by DivDax on 12/29/2023 in #❓┊help
EditAction inside Action
Hey! I'm getting this now as well on a relation manager header action.
3 replies
FFilament
Created by Jocke on 12/28/2023 in #❓┊help
Laravel Vapor gzip
Livewire injecting features comes after all the middleware because it listens to the RequestHandled event. If the response then already is gzipped or brotli'd, then it will not inject the assets and you get this empty page type of thing.
7 replies
FFilament
Created by Jocke on 12/28/2023 in #❓┊help
Laravel Vapor gzip
Ok, it was actually not too hard to figure out 😄
7 replies
FFilament
Created by Wiin on 4/8/2024 in #❓┊help
Problem with gzip middleware
I can confirm the posted solution works ^
5 replies
FFilament
Created by Jocke on 12/28/2023 in #❓┊help
Laravel Vapor gzip
Thank you so much for the solution, I also just needed this. Have you got any clue why this is the solution?
7 replies
FFilament
Created by Matthew on 11/5/2024 in #❓┊help
Filtering a Select Box
You would need to test if CreateAction::make() works, but otherwise a normal Action::make('create') with a form and action works fine for sure.
11 replies
FFilament
Created by Matthew on 11/5/2024 in #❓┊help
Filtering a Select Box
Yes, that does work! You can add eg a tableHeaderAction() with a modal form and then it should work.
11 replies