News for hackers. Stuff that matters.
Re:Union Types have been accepted for PHP 8 by thdrdt on Saturday November 09, 2019 @05:50PM (#21495037)
Laravel is popular because it allows you to setup your project very quickly.

And then the trouble starts. Remember what properties your models had? No? Well so doesn't your IDE. There is just too much magic going on to keep things maintainable.

If you like a framework like Laravel you should go with Symfony instead. But don't use annotations. Keeps things separated so you and your colleagues can find routing and database information at logical places instead of all over the place in classes.

Re:Union Types have been accepted for PHP 8 by xellisx on Saturday November 09, 2019 @08:17PM (#21495728)
Laravel, from my own experience is full of deep rooted magic, and assumptions. Also it throws SOLID out the window.

We use Symfony at work and we turned off the annotations package, use XML mapping for our models.

Of course, Symfony and Doctrine do have some frustation points.

Re:Union Types have been accepted for PHP 8 by thanato0s on Tuesday November 12, 2019 @12:32AM (#21511771)
I have the same experience. Laravel is way too magical for me.

I use Symfony for quite some time and at one point I stopped using Doctrine data mapper. The DBAL and the query builder are enough.

Re:Union Types have been accepted for PHP 8 by xellisx on Tuesday November 12, 2019 @07:11AM (#21513444)
If it were up to me, it would all be SQL queries. Maybe even use the library I rebuilt - https://github.com/ellisgl/GeekLab-GLPDO2
Re:Union Types have been accepted for PHP 8 by kyriakos on Saturday November 09, 2019 @08:08PM (#21495684)
For model properties and a few other IDE related issues with laravel you can use ide helper which generates annotations on your models by inspecting the schema in the database. The ide then uses the annotations and gives you property auto complete among other things.

https://github.com/barryvdh/laravel-ide-helper

Re:Union Types have been accepted for PHP 8 by melicerte on Sunday November 10, 2019 @04:42AM (#21497272)
I would recommend you to give Yii[0] a try. It is a solid, consistent and well thought framework with a vey good documentation. Unfortunately, It has always been eclipsed by new kids on the block frameworks like Laravel but really deserve more credits (provided you accept to let some of the laravel magic go).

I work for a web development company and We have been successfully using Yii for years now, including for medium size projects (in terms of LOC and exposure).

Just my two cents

[0] https://www.yiiframework.com

Re:Union Types have been accepted for PHP 8 by GeneralTspoon on Saturday November 09, 2019 @06:52PM (#21495366)
Regarding model properties - there’s a standard documentation syntax that can be used to document that and give you autocomplete in your IDE (Laravel IDE helper can also auto generate these for you).

Not ideal - since it’s not enforced in anyway (the same as local scope type doc declarations). But can be useful.