A BEAUTIFUL, RESPONSIVE, CUSTOMIZABLE, ACCESSIBLE (WAI-ARIA) REPLACEMENT FOR JAVASCRIPT'S POPUP BOXES FOR LARAVEL
See the codeA beautiful, responsive, customizable, accessible (WAI-ARIA) replacement for JavaScript popup boxes for Laravel — rebuilt from scratch with a fluent, Laravel-native API.
AlertBuilder, ToastBuilder, and InputBuilderAlertType, InputType, and Position enums with IDE autocompletionSweetAlertTrait for dispatching alerts as browser eventsdata-confirm asks before any link or form goes through, no JavaScript to writephp artisan alert:upgrade migrates a v7 codebase for you, with --dry-runAlertDeck is a Laravel app that
exercises every alert this package can produce — in Blade, in Livewire and in
Inertia, plus the guarded-action attributes, all seven themes, and routes
migrated from v7 by alert:upgrade.
composer require realrashid/sweet-alert
php artisan alert:install
Upgrading from v7? See what would change before anything is written:
php artisan alert:upgrade --dry-run
Add the Blade directive to your layout:
<head>
...
</head>
<body>
...
@sweetAlert
</body>
Fire an alert from any controller:
use RealRashid\SweetAlert\Facades\Alert;
Alert::title('Welcome!')
->success()
->text('Your account has been created.')
->flash();
return redirect()->route('dashboard');
Or use the global helper:
alert('Success!', 'Your data has been saved.', 'success');
return redirect()->back();
Ready to explore all the features and options? Dive into our comprehensive documentation:
composer test
Please see CHANGELOG for more information on what has changed recently.
Please see CONTRIBUTING for details.
If you discover a security vulnerability, please help us maintain the security of this project by responsibly disclosing it to us. To report a security vulnerability, please send an email to [email protected]. We'll address the issue as promptly as possible.
If you find Laravel SweetAlert helpful and would like to support my work, you can buy me a coffee. Your support will help keep this project alive and thriving. It's a small token of appreciation that goes a long way.
The MIT License (MIT). Please see License File for more information.
Made with ❤️ from Pakistan
5,655 followers · starred Apr 2019
7 followers · starred Mar 2021
A BEAUTIFUL, RESPONSIVE, CUSTOMIZABLE, ACCESSIBLE (WAI-ARIA) REPLACEMENT FOR JAVASCRIPT'S POPUP BOXES FOR LARAVEL
See the codeA beautiful, responsive, customizable, accessible (WAI-ARIA) replacement for JavaScript popup boxes for Laravel — rebuilt from scratch with a fluent, Laravel-native API.
AlertBuilder, ToastBuilder, and InputBuilderAlertType, InputType, and Position enums with IDE autocompletionSweetAlertTrait for dispatching alerts as browser eventsdata-confirm asks before any link or form goes through, no JavaScript to writephp artisan alert:upgrade migrates a v7 codebase for you, with --dry-runAlertDeck is a Laravel app that
exercises every alert this package can produce — in Blade, in Livewire and in
Inertia, plus the guarded-action attributes, all seven themes, and routes
migrated from v7 by alert:upgrade.
composer require realrashid/sweet-alert
php artisan alert:install
Upgrading from v7? See what would change before anything is written:
php artisan alert:upgrade --dry-run
Add the Blade directive to your layout:
<head>
...
</head>
<body>
...
@sweetAlert
</body>
Fire an alert from any controller:
use RealRashid\SweetAlert\Facades\Alert;
Alert::title('Welcome!')
->success()
->text('Your account has been created.')
->flash();
return redirect()->route('dashboard');
Or use the global helper:
alert('Success!', 'Your data has been saved.', 'success');
return redirect()->back();
Ready to explore all the features and options? Dive into our comprehensive documentation:
composer test
Please see CHANGELOG for more information on what has changed recently.
Please see CONTRIBUTING for details.
If you discover a security vulnerability, please help us maintain the security of this project by responsibly disclosing it to us. To report a security vulnerability, please send an email to [email protected]. We'll address the issue as promptly as possible.
If you find Laravel SweetAlert helpful and would like to support my work, you can buy me a coffee. Your support will help keep this project alive and thriving. It's a small token of appreciation that goes a long way.
The MIT License (MIT). Please see License File for more information.
Made with ❤️ from Pakistan
5,655 followers · starred Apr 2019
7 followers · starred Mar 2021