© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•15mo ago•
1 reply
David | Fortune Validator

ModalContent() to load a livewire component directly

Hi all

I am using a Modal to display a Filament table. I am having to load a view which then calls a livewire component. But it it possible to do something like this

->modalContent(fn (DocketPrices $record) => Blade::render('<livewire.dockets.supplier-orders.list-orders-wrapper :docket_price="$record" />'))
->modalContent(fn (DocketPrices $record) => Blade::render('<livewire.dockets.supplier-orders.list-orders-wrapper :docket_price="$record" />'))


and skip out the view which only exists to call the livewire component. I havnt managed to get this to work yet.

Currently I need to do this:
 ->modalContent(fn (DocketPrices $record): View => view('livewire.dockets.supplier-orders.list-orders-wrapper', ['docket_price' => $record]))
 ->modalContent(fn (DocketPrices $record): View => view('livewire.dockets.supplier-orders.list-orders-wrapper', ['docket_price' => $record]))
which then calls
<livewire:dockets.supplier-orders.list-orders :docket-price="$docket_price" lazy="on-load" />
<livewire:dockets.supplier-orders.list-orders :docket-price="$docket_price" lazy="on-load" />
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Livewire component in Action modalContent? Help
FilamentFFilament / ❓┊help
5mo ago
Livewire Component on ModalContent close modal
FilamentFFilament / ❓┊help
2y ago
Load custom vue js component to modalContent
FilamentFFilament / ❓┊help
3y ago
Directly Passing Form in modalContent
FilamentFFilament / ❓┊help
3y ago