jlrdw's avatar
Level 75

The major changes in 12

With the introduction of our new application starter kits, Laravel Breeze and Laravel Jetstream will no longer receive additional updates.

That is why I suggested to folks in past post to use manual authentication.

https://laravel.com/docs/12.x/authentication#authenticating-users

I had one app with breeze, but it will only take a short time to convert.

0 likes
9 replies
jlrdw's avatar
Level 75

@jeffallen I use laravel authentication but use custom authorization, actually RBAC.

Just a couple of examples:

Seeing if user has correct role

    public static function chkRole($role = null)
    {
        $userrole = Auth::user()->role;
        $checkrole = explode(',', $userrole);
        if (in_array($role, $checkrole)) {
            return true;
        }
        return false;
    }

Ensuring user sees their own data, if admin can see all.

        $petsearch = $petsearch . "%";
        $query->where('petname', 'like', $petsearch);
        if (Authi::chkRole('admin') === false) {
            $userid = Auth::user()->id;
            $query->where('ownerid', '=', $userid);
        }
        $results = $query->orderBy('petname', 'asc')->paginate(5);
        return $results;

There's more to it, but just a couple of examples.

In some business apps, an admin can view accounting data but cannot modify it. So each app is different as to who can to what.

Tray2's avatar

@jlrdw I have seen somewhere that they will continue keeping Jetstream and Breeze support for the coming Laravel releases.

1 like
jlrdw's avatar
Level 75

@Tray2 That will help many who use them. I tried all, including fortify. But I decided to stick with manual authentication from here: https://laravel.com/docs/12.x/authentication#authenticating-users

However like I said I had one done in breeze, I kind of liked breeze. But I like manual better.

I just like flexibility.

I still cannot figure why no starter kit for blade, I guess it's fortify or manual.

But blade combined with regular javascript and fetch or axios js is my choice. I used fetch for a while until I finally tried axios, and chose axios js.

Also @jeffallen @martinbean has an article you might like:

https://martinbean.dev/blog/2021/07/29/simple-role-based-authentication-laravel/

1 like
Tray2's avatar

@jlrdw I agree with you, I like using breeze.

Saw a tweet about Taylor saying that livewire is blade, and he is correct, not just the plain blade we like. However in the newest installer you can choose any starter kit you want, even third party ones, and I bet there is a load of them out there.

1 like
Snapey's avatar
Snapey
Best Answer
Level 122

@Tray2 its the same blade if you dont create any Livewire components (is Taylors point)

1 like
Merklin's avatar

If you don't want a starter kit, Laravel Fortify is still there. You only have to create the blade files and register them in the FortifyServiceProvider.

2 likes

Please or to participate in this conversation.