PHP code example of croudtech / laravel-repositories

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

    

croudtech / laravel-repositories example snippets



namespace App\Controllers;

use \CroudTech\Repositories\TestApp\Repositories\Contracts\UserRepositoryContract;

class UserController extends Controller
{
  protected $repository;

  public function __construct(UserRepositoryContract $user_repository)
  {
    $this->repository = $user_repository;
  }
}