Answers for "laravel access request in provider"

PHP
0

laravel access request in provider

public function register()
{
    $this->app->bind('MyInterface', function () {
        $request = app(\Illuminate\Http\Request::class);

        return app(MyImplementation::class, [$request->foo]);
    }
}
Posted by: Guest on April-05-2020

Code answers related to "laravel access request in provider"

Browse Popular Code Answers by Language