omnilight / yii2-sweetalert
此包最新版本(1.0.4)没有可用的许可证信息。
为 Yii2 框架的 SweetAlert 资产
1.0.4
2016-04-03 19:30 UTC
Requires
- php: >=5.4.0
- bower-asset/sweetalert: 1.1.*
- yiisoft/yii2: 2.0.*
README
为 Yii2 框架的 SweetAlert 资产
安装
安装此扩展的首选方法是使用 composer。
在 composer.json 中添加 composer 依赖
"omnilight/yii2-sweetalert": "1.0.*"
然后运行 composer update
用法
只需在视图中注册 SweetAlert 资产,如下所示
use omnilight\assets\SweetAlertAsset;
SweetAlertAsset::register($this);
您就可以开始使用 SweetAlert JS 代码了
swal("Hello world!");
许可证
扩展程序以 MIT 许可证发布。有关详细信息,请参阅捆绑的 LICENSE.md
文件。