NEW Laravel Pennant: Overview and Short Course

preview_player
Показать описание
Presenting to you the new Laravel Pennant for managing feature flags with Laravel 10.

- - - - -
Support the channel by checking out my products:

- - - - -
Other places to follow:
Рекомендации по теме
Комментарии
Автор

This is definitely for larger projects who are running A/B testing not for policy. Like if you want to know if a user is more likely to buy a product when the button is red, green, blue, etc. Then you would use pennant to assign a feature to a given user. The feature is stored in the DB because in most cases you would want to track the behavior associated with a feature. If you are just using policy based features then you cannot see why a feature may have caused a user to unsubscribe.

wadecodez
Автор

Its really a wonderful feature in laravel-10. We can handle some specific modules access like for super admin user. Your example was also cool with the middleware method. Great !
here is my one question @Korop. Can pennant be used to manage user permissions?

ahsanrasheed
Автор

Of course, it would be more correct to return Response

But, here I came across auto-documentation, and it turned out that it is much more convenient to return a Resource (own class that extend JsonResource), which can be parsed and displayed in the auto generated documentation for API

artyomman
Автор

Everyone: feature flags != roles and permissions.

martinbean
Автор

So we can use it for Authorization as well?
Like If I am guest user certain part of layout shouldn't be visible to me and this way I can avoid using gates and permissions. Am I right?

BadarShafiq-wo
Автор

Why can't we just use permission? For example the permission to be 'view tasks'. And then we check if $user->can('view tasks') then show that. We can apply it to anywhere and also in the policy if we want to have more complex condition for the access.

aminraeisi
Автор

If your application doesn't use Gates and Permissions, and if you need to hide features for some users, this will come in handy. If you already have Gates and Permissions implemented, you can achieve the same thing through that as well.

smith
Автор

Suppose you have one default database, and from default database, your getting another database name (can be of n number), and I want to switch that user to use that database dynamically (until the user logs out), also Try to explain in optimized way, as setting connection with every request takes time or some of memory also, is there any best solution?

AkashMaurya-qlux
Автор

I did not understand, what is the deference between policy and pennant ?

firdavs.ibodullayev
Автор

Hey! What is your code style in your PHPStorm? I love how clear it is. Thanks for the demo!

Elelalem
Автор

You are "FAST", like really really fast... 🔥

JagdeepSinghKalsi
Автор

Hey Povilas, another great video. The section on middleware raised the question in my mind about Features vs. Policies/Gates "can". Do you think they are related in any way? Do we get to choose between them? Thanks

bhaidar
Автор

Plz Make Ecommerce Project in Laravel with Admin panel and Payment gateway

hubesh
Автор

isnt that just like gate but in different way why should we use this insted of gate and policy thans for your videos

awadalsharif
Автор

I guess the Laravel developers were stuck for new ideas, so they just threw in some roles and permissions and called it a day. But hey, if it ain't broke, don't fix it, right? 😅👨‍💻🔒

AliMuhammadRajwa
Автор

Wow! Laravel team really running out of ideas for new features 😂 maybe they need to stop accepting sponsor code and start actually accepting community code?

Laflamablanca