aldozumaran/laravel-quasar-init

This package is abandoned and no longer maintained. No replacement package was suggested.

Laravel and Quasar JWT auth

Installs: 83

Dependents: 0

Suggesters: 0

Security: 0

Stars: 2

Watchers: 1

Forks: 1

Open Issues: 15

Language:JavaScript

2.0.4 2019-05-31 10:04 UTC

README

68747470733a2f2f6c61726176656c2e636f6d2f6173736574732f696d672f636f6d706f6e656e74732f6c6f676f2d6c61726176656c2e737667

Laravel & Quasar JWT Auth

Backend

  • Quasar 0.17 - branch 1.0

  • Quasar 1.0 - branch master

    composer require aldozumaran/laravel-quasar-init

    php artisan vendor:publish --provider="Mz2p\LaravelQuasarInit\LaravelQuasarInitServiceProvider"

    php artisan jwt:secret

Edit app/Exceptions/Handler.php

<?php
namespace App\Exceptions; 
use Mz2p\LaravelQuasarInit\Exceptions\Handler as ExceptionHandler;

class Handler extends ExceptionHandler 
{ 
}

Add middleware in app/Http/Kernel.php

'jwt' => \Mz2p\LaravelQuasarInit\Http\Middleware\JWT::class,

Change auth api driver

'guards' => [
    'api' => [
        'driver' => 'jwt',
        'provider' => 'users',
    ],
],

Add in routes/api.php

LaravelQuasar::routes();    

Edit User model:

<?php

namespace App;

use Mz2p\LaravelQuasarInit\Models\User as JwtUser;

class User extends JwtUser
{
}

And run server

php artisan serve

Frontend

cd resources/modules/admin
npm install
quasar dev

License

This package is open-sourced software licensed under the MIT license.