Skip to content

Instantly share code, notes, and snippets.

View russsiq's full-sized avatar

Рустам russsiq

  • Россия, Приморский край
View GitHub Profile
<?php
namespace App\Services\Dto;
abstract class AbstractDto
{
/**
* AbstractRequestDto constructor.
* @param array $data
*/
@russsiq
russsiq / Transport.php
Created June 15, 2021 03:15 — forked from DarkGhostHunter/Transport.php
An invokable class for route binding
<?php
namespace App\Http\Bindings;
class Transport
{
/**
* Resolve the route bind
*
* @param string $value
@russsiq
russsiq / ShareAuthenticatedUser.php
Created June 15, 2021 03:14 — forked from DarkGhostHunter/ShareAuthenticatedUser.php
Shares the Authenticated User in all views
<?php
namespace App\Http\Middleware;
use Closure;
use Illuminate\Contracts\View\Factory;
use Illuminate\Contracts\Auth\Authenticatable;
class ShareAuthenticatedUser
{
@russsiq
russsiq / Container.php
Created June 15, 2021 03:13 — forked from DarkGhostHunter/Container.php
Container class to pass through the next method.
<?php
class Container
{
protected $target;
protected $value;
public function __construct($target, $value)
{
$this->target = $target;