PHP code example of wsssoftware / laraveltoolkit

1. Go to this page and download the library: Download wsssoftware/laraveltoolkit 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/ */

    

wsssoftware / laraveltoolkit example snippets


use Illuminate\Support\Number;
use Illuminate\Support\Str;
use Laraveltoolkit\Measurement\Enums\LengthUnit;
use Laraveltoolkit\Rules\DocumentRule;

length(2.54, 'cm')->to(LengthUnit::MILLIMETER)->value(); // 25.4

Str::applyMask('12345678901', '000.000.000-00'); // 123.456.789-01

Number::spellCurrency(42.50, in: 'BRL', locale: 'pt_BR');

$request->validate([
    'document' => ['
bash
php artisan vendor:publish --tag=laraveltoolkit-config
bash
php artisan vendor:publish --tag=laraveltoolkit-migrations
php artisan migrate