voorhof/flash
最新稳定版本:v1.0.2
Composer 安装命令:
composer require voorhof/flash
包简介
A simple flash message service for Laravel applications, using Bootstrap alerts
README 文档
README
A simple, elegant flash messaging package for Laravel applications, using Bootstrap alerts as the view.
Installation
You can install the package via composer:
composer require voorhof/flash
The package will automatically register its service provider.
You can publish the configuration file with:
php artisan vendor:publish --provider="Voorhof\Flash\FlashServiceProvider" --tag="flash-config"
You can publish the views with:
php artisan vendor:publish --provider="Voorhof\Flash\FlashServiceProvider" --tag="flash-views"
Usage
use Voorhof\Flash\Facades\Flash;
// Flash a success message
Flash::success('Item created successfully!');
// Flash a warning message
Flash::warning('Please review your input.');
// Flash a danger/error message
Flash::danger('An error occurred!');
// Flash an info message
Flash::info('Here is some information.');
In your Blade template, include the flash message component:
@include('flash::flash')
Credits
License
The MIT License (MIT). Please see License File for more information.
统计信息
- 总下载量: 296
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2025-07-24