1. Go to this page and download the library: Download ariefng/filament-calculator library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
ariefng / filament-calculator example snippets
use Ariefng\FilamentCalculator\CalculatorPlugin;
use Filament\Panel;
public function panel(Panel $panel): Panel
{
return $panel
->plugin(CalculatorPlugin::make());
}
use Ariefng\FilamentCalculator\Actions\CalculatorAction;
use Filament\Forms\Components\TextInput;
TextInput::make('amount')
->suffixAction(CalculatorAction::make());
TextInput::make('amount')
->prefixAction(CalculatorAction::make());