I installed this package:
composer require tymon/jwt-auth "^1.0"
Then ran:
php artisan vendor:publish --provider="Tymon\JWTAuth\Providers\LaravelServiceProvider"
And then:
php artisan jwt:secret
I also added this to the app.php config file:
Tymon\JWTAuth\Providers\LaravelServiceProvider::class,
The commands ran without errors. However, following the documentation I'm trying to implement the JWTSubject interface on the User model. However like this:
use Tymon\JwTAuth\Contracts\JWTSubject;
class User extends Authenticatable implements JWTSubject
{
The JWTSubject is underlined with red and it says:
Undefined type 'Tymon\JwTAuth\Contracts\JWTSubject'.
Do you know what can be the issue? Thanks