Skip to content

Instantly share code, notes, and snippets.

@jsdecena
Created March 14, 2018 01:45
Show Gist options
  • Save jsdecena/67ebd14b31707b14dc6e197f40c61cce to your computer and use it in GitHub Desktop.
Save jsdecena/67ebd14b31707b14dc6e197f40c61cce to your computer and use it in GitHub Desktop.
<?php
namespace App\Providers;
use App\Articles\Repositories\ArticlesRepository;
use App\Articles\Repositories\Interfaces\ArticleRepositoryInterface;
use Illuminate\Support\ServiceProvider;
class RepositoryServiceProvider extends ServiceProvider
{
/**
* Bind the interface to an implementation repository class
*/
public function register()
{
$this->app->bind(
ArticleRepositoryInterface::class,
ArticlesRepository::class
);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment