Download the PHP package fidum/laravel-nova-metrics-polling without Composer
On this page you can find all versions of the php package fidum/laravel-nova-metrics-polling. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download fidum/laravel-nova-metrics-polling
More information about fidum/laravel-nova-metrics-polling
Files in fidum/laravel-nova-metrics-polling
Package laravel-nova-metrics-polling
Short Description Easily add polling to all your Laravel Nova metrics and cards!
License MIT
Homepage https://github.com/fidum/laravel-nova-metrics-polling
Informations about the package laravel-nova-metrics-polling
Easily add polling to all your Laravel Nova metrics and cards!
Easily add polling to all your Laravel Nova metrics and cards!
Installation
You can install the package via composer:
Usage
Firstly, just add the SupportsPolling
trait to any of your Metrics or Card classes:
Then in the Dashboard, Resource or Lens cards
method where you have registered your card you can call refreshIntervalSeconds
and pass in the number of seconds you want the interval to be between refresh requests. You can
also pass a closure as needed.
If preferred, you can call refreshIntervalMilliseconds
instead and pass in the number of milliseconds you want the interval to be between refresh requests.
That is it, your cards should now be polling at the specified intervals! :tada:
Testing
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Credits
- Dan Mason
- All Contributors
License
The MIT License (MIT). Please see License File for more information.