moathdev / sweetalert by moathdev

A Sweet Alert package for Laravel 5.2
251
10
1
Package Data
Maintainer Username: moathdev
Maintainer Contact: Moath@moath.co (moathdev)
Package Create Date: 2016-09-15
Package Last Update: 2019-09-05
Home Page:
Language: CSS
License: MIT
Last Refreshed: 2024-11-19 03:00:29
Package Statistics
Total Downloads: 251
Monthly Downloads: 2
Daily Downloads: 0
Total Stars: 10
Total Watchers: 1
Total Forks: 1
Total Open Issues: 0

Laravel 5.2 SweetAlert

all appreciation to laracasts.com i just can't sleep ! so i created package :)

##Installation

composer require moathdev/sweetalert

After install this package you have to set the service provider on your config/app.php file

Moathdev\Sweetalert\SweetalertServiceProvider::class,

Then you just need to publish files ! Copy and paste it

php artisan vendor:publish --provider="Moathdev\Sweetalert\SweetalertServiceProvider"

Then in your master view add those styles and scripts. Put this style between the tags

 <head>
        <link href="/css/sweetalert.css" rel="stylesheet"/>

Add the JS script and include flash view before close your tag.

        <script src="/js/sweetalert.min.js"></script>
        @include('Flash')
    </body>

###Usage

it's so Easy !


 flash('title','message','success',true);

 // there is 4 Types 1-warning 2-error 3-success 4-info

 // showConfirmButton yes = true no = false

###Issues

If you have any questions or issues, please open an Issue .