getting logged in user details in laravel code example
Example 1: current user laravel
$user = auth()->user(); print($user->id);print($user->name);print($user->email);
Example 2: get user auth in laravel
Auth::user();
$user = auth()->user(); print($user->id);print($user->name);print($user->email);
Auth::user();