-
Create a componet notification.blade.php
-
Add to your layout
<x-notification />
-
Add Macro to your AppServiceProvider.php
-
Call Macro $this->notify('Some Message', 'Yeah Baby!', 'success');
Options:
- $this->notify('You saved something.'); //Default Success Toast NO TITLE
- $this->notify('You saved something.', 'Success!'); //Default Success Toast WITH TITLE
- $this->notify('You have amessage', 'Message', ''); //Message Toast WITH TITLE
- $this->notify('You saved something.', 'Yay You!', 'success'); //success Toast WITH TITLE
- $this->notify('Oh No', 'There was a problem', 'error'); //Error Toast WITH TITLE
- $this->notify('You can't do that...', 'Warning...', 'warning'); //Warning Toast WITH TITLE
- $this->notify('Here's Something New!', 'New Product', 'info'); //Info Toast WITH TITLE