4 ms·
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
by thdrdt 7y ago
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.
- xellisx 7y agoLaravel, 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.
- thanato0s 7y agoI 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.
- xellisx 7y agoIf it were up to me, it would all be SQL queries. Maybe even use the library I rebuilt - https://github.com/ellisgl/GeekLab-GLPDO2 https://github.com/ellisgl/GeekLab-GLPDO2
- GeneralTspoon 7y agoRegarding 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.
- kyriakos 7y agoFor 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 https://github.com/barryvdh/laravel-ide-helper
- melicerte 7y agoI 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 https://www.yiiframework.com