Skip to content

Instantly share code, notes, and snippets.

<?php
declare(strict_types=1);
namespace App\VO;
use InvalidArgumentException;
/**
* Class Email обьект значение которое инкапсулирует в себе email значение
<?php
declare(strict_types=1);
namespace App\VO;
use InvalidArgumentException;
/**
* VinCode class.
<template>
<v-container fluid>
<v-alert v-if="getError || errorGetReport" type="warning">
<v-card-text>{{ getError || errorGetReport }}</v-card-text>
</v-alert>
<v-row>
<v-col cols="12">
<v-card>
<v-card-text>
<v-row align="center">
<?php
namespace App\EventSubscriber;
use Exception;
use InvalidArgumentException;
use Psr\Log\LoggerInterface;
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpKernel\Event\ExceptionEvent;
@BerezhniyDmitro
BerezhniyDmitro / cheatsheet-elasticsearch.md
Last active February 5, 2020 11:45 — forked from ruanbekker/cheatsheet-elasticsearch.md
Elasticsearch Cheatsheet : Example API usage of using Elasticsearch with curl

FWIW: I didn't produce the content presented here (the outline from Edmond Lau's book). I've just copy-pasted it from somewhere over the Internet, but I cannot remember what exactly the original source is. I was also not able to find the author's name, so I cannot give him/her the proper credits.


Effective Engineer - Notes

What's an Effective Engineer?

<?php
declare(strict_types=1);
namespace App\Domain\Company\Factory;
use App\Domain\Company\DTO\CompanyRegistrationDTO;
use App\Domain\ValueObjects\Okpo;
use App\Entities\Company\Company;
use App\Entities\PersonalCabinet\PersonalCabinet;
<?php
declare(strict_types=1);
namespace App\Domain\Company\Factory;
use App\Domain\Company\DTO\CompanyRegistrationDTO;
use App\Domain\ValueObjects\Okpo;
use App\Entities\Company\Company;
use App\Infrastructure\Repository\PersonalCabinet\PersonalCabinetRepository;
<?php
namespace App\ValueObjects;
use Webmozart\Assert\Assert;
/**
* Class MobilePhone обьект-значения мобильного телефона
*/
class MobilePhone implements FromStringCreatable
#!/usr/bin/env bash
STAGED_FILES_CMD=`git show --pretty="" --name-only $CI_COMMIT_SHA --diff-filter=ACMR | grep \\\\.php`
if [ -z "$STAGED_FILES_CMD" ]; then
echo -e '\e[32m Файлов нет, пропускаю.\e[0m';
exit 0;
else
php ./vendor/bin/phpcs --error-severity=1 --warning-severity=8 --colors $STAGED_FILES_CMD
php ./vendor/bin/phpcs --error-severity=1 --warning-severity=8 --colors --report=summary $STAGED_FILES_CMD