It will be possible only with minimum PHP 8.4+ requirement, so only Laravel 13+ probably Also, imagine how many developers would be angry that they would need to re-code big parts of their projects. So I don't see it coming any time soon.
They could just add another library, just another way of doing things right? Property hooks are also great for intellisense, allowing the editor to give more sensible suggestions and navigating the code could be a little easier
@@LaravelDaily Maybe The logic in Laravel will be the same as it was, but in feature update 13+, magic will be dropped and language features will be used.
As already mentioned, that would be a big rewrite but if they allowed it in a way of "another way of defining and using", the same how they did with new and old way of defining accessors/mutators. Some version checking will be needed, probably, otherwise it would be a massive roadblock before upgrading to a certain Laravel version if they chose to overwrite it to property hooks.
@@ward7576 Agreed, 8.4 is new now, but a few years down the road it'll be common, at least for new projects. We'll see what the Laravel team decides to do :)
In my opinion the coolest feature released in php 8.4 is lazy objects. Not for as, but for framework developers. Imagine how cool it would be to only instantiate some class when it's needed. We could get much better performance with much less memory usage
For me php property hooks are much more straightforward than the eloquent's mutators and accessors which is hidden specially for people that are new to laravel.
Regarding 3:42, I was wondering, if you don't use the factory pattern at all (a bit weird, that it is also not to be found in the laravel documentation)? What do you use instead? And how?
I don't remember using it lately, to be honest. But maybe my projects are too simple, that reminded me that I need to get back to creating more complex projects.
The new property hooks seems to allow a big mess, you can have both a set{PropertyName} function and a defined property hook for that property. I just fear for when I go to a code base and has both being used, and I hope that PHPStorm adds something to know for sure that a property is actually a hook and can have side-effects
My personal feeling about 8.4 is that the majority (if not all) of the features were targeted at framework maintainers. For the rest of us developing on top of a framework the features have little impact on our code. Don't get me wrong, this is a good thing as it speaks to a mature language. GoLang mature public api across versions over the years comes to mind.
Currently Pint has not updated support for 8.4 because its major dependency PHP-CS-Fixer takes time to move to next version. So I am still hanging out on 8.3 meanwhile.
If you are talking about juniors and mid developers. I agree But senior developers that build skelton projects, reusable packages, HMVC architectures, different design patterns codes. Would be very interested in such features as property hooks. We build a lot of code on top of laravel as code generators, dynamic level of software plugins and such on
Eloquent attributes are great, but these are for Laravel. Remember that Laravel is not a separate language, it still uses PHP. And with a simple Laravel it is almost always not enough- we need to extend classes, write custom actions/services/processors/resolvers/repositories/etc. And this is a step where we are using PHP native stuff.
Googled it, there are a few packages and tutorials, like this: - laravel-news.com/fastlogin - www.reddit.com/r/laravel/comments/ibx6cf/laravel_login_users_with_their_fingerprints/
It's interesting how author of the video makes a review of new features though the prism of laravel ? In case it's not useful for laravel, maybe it's time for the laravel to upgrade and adopt new features ?
You know, Something i am eager to see in modern php is " Multiple inheritance ". Imagin Laravel 13+ with multiple inheritance. What do you think about it? would php developers achieve that ?
Well, I have a course called "PHP for Laravel developers" which was surprisingly popular at the time I released it :) laraveldaily.com/course/php-laravel
Maybe for developers that use Laravel, this won't be a big deal. But for developers that develop Laravel itself, this might be usefull.
Good point about different audiences!
@@LaravelDaily I am pretty sure I am not the only viewer who has ever submitted a PR to Laravel GitHub.
Wild idea - maybe its finally a chance for Laravel to drop some of its magic via Accessors and Mutators and actually use php?
It will be possible only with minimum PHP 8.4+ requirement, so only Laravel 13+ probably
Also, imagine how many developers would be angry that they would need to re-code big parts of their projects.
So I don't see it coming any time soon.
They could just add another library, just another way of doing things right? Property hooks are also great for intellisense, allowing the editor to give more sensible suggestions and navigating the code could be a little easier
@@LaravelDaily
Maybe The logic in Laravel will be the same as it was, but in feature update 13+, magic will be dropped and language features will be used.
As already mentioned, that would be a big rewrite but if they allowed it in a way of "another way of defining and using", the same how they did with new and old way of defining accessors/mutators. Some version checking will be needed, probably, otherwise it would be a massive roadblock before upgrading to a certain Laravel version if they chose to overwrite it to property hooks.
@@ward7576 Agreed, 8.4 is new now, but a few years down the road it'll be common, at least for new projects. We'll see what the Laravel team decides to do :)
I like the support to declare properties in Interfaces. I think this is where the news of Property hooks seems to fit more into my daily work.
I use Laravel for my projects, but I do prefer to use native PHP where it can, since Laravel is just a layer between PHP. Great video!
We are using Doctrine as ORM and property hooks will be a great step forward for clean code :)
In my opinion the coolest feature released in php 8.4 is lazy objects. Not for as, but for framework developers. Imagine how cool it would be to only instantiate some class when it's needed. We could get much better performance with much less memory usage
For me php property hooks are much more straightforward than the eloquent's mutators and accessors which is hidden specially for people that are new to laravel.
Regarding 3:42, I was wondering, if you don't use the factory pattern at all (a bit weird, that it is also not to be found in the laravel documentation)? What do you use instead? And how?
I don't remember using it lately, to be honest. But maybe my projects are too simple, that reminded me that I need to get back to creating more complex projects.
The new property hooks seems to allow a big mess, you can have both a set{PropertyName} function and a defined property hook for that property. I just fear for when I go to a code base and has both being used, and I hope that PHPStorm adds something to know for sure that a property is actually a hook and can have side-effects
as ex-Mobile Kotlin Developer, that set get usually I used in MVVM concept.
But yeah, Laravel developer won't need this but thank you.
property hooks might be useful in DTO classes
My personal feeling about 8.4 is that the majority (if not all) of the features were targeted at framework maintainers. For the rest of us developing on top of a framework the features have little impact on our code.
Don't get me wrong, this is a good thing as it speaks to a mature language. GoLang mature public api across versions over the years comes to mind.
Currently Pint has not updated support for 8.4 because its major dependency PHP-CS-Fixer takes time to move to next version. So I am still hanging out on 8.3 meanwhile.
If you are talking about juniors and mid developers. I agree
But senior developers that build skelton projects, reusable packages, HMVC architectures, different design patterns codes. Would be very interested in such features as property hooks.
We build a lot of code on top of laravel as code generators, dynamic level of software plugins and such on
Eloquent attributes are great, but these are for Laravel. Remember that Laravel is not a separate language, it still uses PHP. And with a simple Laravel it is almost always not enough- we need to extend classes, write custom actions/services/processors/resolvers/repositories/etc. And this is a step where we are using PHP native stuff.
From my understanding Herd is tool that would replace things like Laragon or Xampp right? Or in conjunction with?
Replace, yes.
is there any way to use biometric authentication with laravel?
Googled it, there are a few packages and tutorials, like this:
- laravel-news.com/fastlogin
- www.reddit.com/r/laravel/comments/ibx6cf/laravel_login_users_with_their_fingerprints/
have you tried google your own words? "biometric authentication with laravel"
@@krekas I sometimes wonder how these developers even have a full-time job not being able to google their own questions.
Maybe he has googled it, but asked anyway to get a different solution to his problem from people with different experience
@williandamascenomusic doubt
It's interesting how author of the video makes a review of new features though the prism of laravel ? In case it's not useful for laravel, maybe it's time for the laravel to upgrade and adopt new features ?
I'm sure they will adopt new features in the future versions, as they did with return types, PHP attributes and other things.
You know, Something i am eager to see in modern php is " Multiple inheritance ".
Imagin Laravel 13+ with multiple inheritance.
What do you think about it?
would php developers achieve that ?
We could use getters and setters in DTOs
Does it mean Laravel devs are not php devs? 🤔
Well, I have a course called "PHP for Laravel developers" which was surprisingly popular at the time I released it :)
laraveldaily.com/course/php-laravel
Yes.
Yeah. But the first was Vue with computed properties.
Would be nice if traits can use abstract variables. It is php related not laravel xD
Hy, I m beginner and learned laravel but wanted to practice and can work as internee free of cost for obtiaing experience.
Sorry I'm not hiring at the moment
Great sir
Let your browser update itself for once, damn it! Seems like in every video your browser is outdated lmao