My very Laravel first plugin, based on

dev-master 2019-09-17 20:00 UTC

This package is auto-updated.

Last update: 2024-04-18 06:17:54 UTC


My very first plugin, based on

This is strictly designed as a session based alert for errors and the such.

This is not supposed to be used as a general alert.

How to make an alert

To make an alert:

Flash::error('You got hell to pay')

which supports these types of alerts:

  • error
  • success
  • warning
  • info

How to make it dismissible

Simply add a second paramter of true or false depending on whether you want it dismissible or not.

Flash::error('You got hell to pay', true)

This alert can be dismissed because it has the second parameter of true.

How to display alerts in my template



This plugin registers all of its views at the flash namespace and only has one view, flash.

This plugin also registers the view for publishing as such you can do this to enable the view to be overridden:

php artisan vendor:publish --provider="sammaye\Flash\Providers\FlashServiceProvider"