Re:The Future of HHVM
by thinkindie on Monday September 18, 2017 @04:10PM
(#15279094)
Laravel is probably not the best example in terms of improving PHP landscape in terms of code/architecture quality: Symfony is way more prominent in that. It's not a case that Laravel is using many components from Symfony.
[ Parent
| on HN ]
it is weird for me why Laravel is so popular now given that as far as I've read documentation, a lot of it is written in static class calls, which is opposite of OOP and all good pratices coming with OOP.. I understand that it's kind of rails and gives short-term productivity, but if you have complex project, it will become an issue if majority of project code is spaghetti code without DI, IoC and so on.
Laravel encourages DI via Service Containers: https://laravel.com/docs/5.5/container
And, Laravel static methods (as you see in the docs as Facades) are not truly static (and testable/mockable).
https://laravel.com/docs/5.5/facades#facades-vs-dependency-i...
http://usman.it/laravel-4-uses-static-not-true/
thanks for response, will read it!
Re:The Future of HHVM
by dabernathy89 on Monday September 18, 2017 @05:33PM
(#15279804)
Laravel's facades are not static method calls, and they are all configurable through Laravel's dependency container:
https://laravel.com/docs/5.5/facades
- edited to remove snark
thanks for link, it explains a lot!
Everyone else answered your questions/misconceptions about Laravel, but Laravel owes a lot of its popularity to Laravel Forge [0] and the tooling around deployment and code management. It is a tremendous tool.