| Name | Modified | Size | Downloads / Week |
|---|---|---|---|
| Parent folder | |||
| README.md | 2026-05-18 | 1.5 kB | |
| v4.2.0 - Drive loading spinners and live alert updates straight from PHP source code.tar.gz | 2026-05-18 | 13.7 kB | |
| v4.2.0 - Drive loading spinners and live alert updates straight from PHP source code.zip | 2026-05-18 | 23.4 kB | |
| Totals: 3 Items | 38.6 kB | 0 | |
v4.2.0 — Drive loading spinners and live alert updates straight from PHP
Three new methods give your Livewire components server-driven control over an open alert — no more close-and-reopen flicker.
✨ New
-
asLoading(?string $title = null)— preset for non-dismissable spinne and backdrop clicks; triggersSwal.showLoading()on open. Default title'Loading...', override with a string argument.:::php LivewireAlert::title('Saving...')->asLoading()->show();
-
close()— dismiss the current alert from the server.:::php LivewireAlert::close();
-
update(?array $options = null)— mutate the open alert in place viaSwal.update(). Two forms:
Fluent — only explicitly-set options emitted, config defaults not merged:
:::php
LivewireAlert::title('Almost done')->text('90%')->update();
Explicit payload:
:::php
LivewireAlert::update([
'title' => 'Almost done',
'text' => '90%',
]);
No-op (with console warning) when no alert is visible. Guards run before calal` no longer throws.
🧩 Why this matters
Pair asLoading() + wire:poll + update() to drive Bus::batch() progreany phased task — all from PHP, with the alert updating live.
🛡 Contract
Alertable interface extended with the three new methods (additive — no break).
Full Changelog: https://github.com/jantinnerezo/livewire-alert/compare/v4.2.0...v4.2.0