jonlynch / laravel-dashboard-uk-tide-tile
A package to add UK tide tiles to Laravel Dashboard
Requires
- php: ^7.4
- spatie/laravel-dashboard: >=1.0 <3.0
Requires (Dev)
- phpunit/phpunit: ^9.0
This package is auto-updated.
Last update: 2024-11-08 05:09:50 UTC
README
A package to show UK tide information on the Laravel Dashboard.
Installation
You can install the package via composer:
$ composer require jonlynch/laravel-dashboard-uk-tide-tile
Usage
In your dashboard view you use the livewire:uk-tide-tile
component.
<x-dashboard> <livewire:uk-tide-tile position="a1"/> </x-dashboard>
Add the config to the tiles sections of your config/dashboard.php
// in config/dashboard.php return [ // ... tiles => [ 'tides' => [ 'api_key' => env ('TIDE_API_KEY'), 'station_id' => '0435', 'location' => 'St Bees' ], ]
In app\Console\Kernel.php you should schedule the JonLynch\TideTile\Commands\FetchMetOfficeDataCommand to run every hour.
// in app\Console\Kernel.php protected function schedule(Schedule $schedule) { $schedule->command(\JonLynch\TideTile\Commands\FetchTidesDataCommand::class)->hourly(); }
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security
If you discover any security related issues, please email Jon Lynch instead of using the issue tracker.
Credits
License
The MIT License (MIT). Please see License File for more information.