1. Go to this page and download the library: Download isakzhanov-r/laravel-dto 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/ */
isakzhanov-r / laravel-dto example snippets
use IsakzhanovR\DataTransferObject\DataTransferObject;
use IsakzhanovR\ValueObject\Email // example
class UserData extends DataTransferObject
{
public $id;
public string $name;
/**
* @var \IsakzhanovR\ValueObject\Email
* @throws \App\Exceptions\EmailDataExeption
*/
public Email $email;
/**
* @var IsakzhanovR\DataTransferObject\FiledDTO[] - example
*/
public array $fields;
}