swooinc / nova-countdown
A countdown card for Laravel Nova.
Installs: 24 351
Dependents: 0
Suggesters: 0
Security: 0
Stars: 13
Watchers: 3
Forks: 4
Open Issues: 1
Language:Vue
Requires
- php: >=7.1.0
- illuminate/support: ~5.6.0|~5.8.0|^6.0|^7.0|^8.0
- laravel/nova: *
README
A countdown card for Laravel Nova.
Installation
Install the package with composer using the following command:
composer require swooinc/nova-countdown
Usage
You can pass a Carbon instance for the countdown.
<?php namespace App\Nova; use Swooinc\NovaCountdown\NovaCountdown; class User extends Resource { // Other methods /** * Get the cards available for the request. * * @param \Illuminate\Http\Request $request * @return array */ public function cards(Request $request) { return [ (new NovaCountdown) ->to(now()->addDays(30)) ->label('30 Days Later'), ]; } }
License
The MIT License (MIT). Please see License File for more information.