Download the PHP package aliowa/livewire-toasts without Composer
On this page you can find all versions of the php package aliowa/livewire-toasts. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download aliowa/livewire-toasts
More information about aliowa/livewire-toasts
Files in aliowa/livewire-toasts
Package livewire-toasts
Short Description Laravel Livewire toast notifications using Alpine JS
License MIT
Homepage https://github.com/aliowacom/livewire-toasts
Informations about the package livewire-toasts
Livewire Toasts
This package allows you to dynamically display toasts notifications via Laravel Livewire components. Toasts are powered by AlpineJS and are displayed without any delay.
Documentation
- Livewire Toasts
- Documentation
- Requirements
- Installation
- Usage
- Livewire Component Setup
- Showing Toasts
- Publishing Assets
- Custom View
Requirements
- AlpineJS version 3.0 or higher
Installation
You can install the package via composer:
Add the x-aliowa-livewire-toasts
component to your app layout view:
By default toasts are styled with TailwindCSS. To autodiscover necessary classes, either publish toasts views or add package views location to your tailwind.config.js
file:
Usage
Livewire Component Setup
Add Toastable
trait to your livewire component:
Showing Toasts
Show a toast providing a message to one of four methods toastSuccess
, toastWarning
, toastDanger
, toastInfo
:
Publishing Assets
Custom View
By default toasts view file uses TailwindCSS, but you can publish and change the way toasts will look on your website.
Now edit the view file resources/views/vendor/components/aliowa/livewire-toasts/components/toasts.blade.php
. The package will use this view to render the component.