I am using Laravel and PHPStorm.
The auto completion works for all models, just not for the 'User', when I call it with Auth::user().
When I call the Auth::user() I get the right user object, but the return type of Auth::user() is Authenticatable and not User. So I get no code completion for my user object which is very anoying because I use it very often. I think the problem has something to do with the return type of Auth::user() because it is Authenticatable and not User.
In the config/auth.php I already set the model to app/User::class.
Can you tell me how to cast the return value to the User model?
In this example you can see the behaviour.


