How to redirect without making a full page request?

Panel uses spa()
class AdminPanelProvider extends PanelProvider
{
public function panel(Panel $panel): Panel
{
return $panel
->spa();
}
}
class AdminPanelProvider extends PanelProvider
{
public function panel(Panel $panel): Panel
{
return $panel
->spa();
}
}
In my PostResource's $form I have a custom action which redirects to the table.
Action::make('publish')
->action(function ($record) {

$record->publish();

return redirect(self::getUrl('index'));
})
Action::make('publish')
->action(function ($record) {

$record->publish();

return redirect(self::getUrl('index'));
})
Does Filament have its own redirect method which doesn't break the SPA UX?
0 Replies
No replies yetBe the first to reply to this messageJoin