Sep 24, 2017
0
Level 3
Service Provider IoC, bindings diferrence
I have in my service Provider the following code in register function
use App\Modules\Core\Includes\Services\Human;
public function register()
{
$this->app->bind('human', 'App\Modules\Core\Includes\Services\Human');
$this->app->bind('human', function() {
return new Human();
});
}
What is the difference between this two binding ?
Please or to participate in this conversation.