- Published on
No Love for Laravel
- Authors
- Name
- Christopher Snizik
- @casinnola
Anti-Laravel sentiment in the PHP subreddit, complete with a request to ban Laravel discussions
Laravel is the most widely used PHP framework, to the dismay of many PHP devs. A post on the PHP sub entitled, "Laravel considered harmful" got over 500 upvotes and comments in less than a week, so I decided to take a look. The gist of the original post was: Laravel is harmful b/c it doesn't teach best practices, giving new and junior devs a distorted senses of PHP and programming in general.
A Brief Introduction to Laravel
For the uninitiated, Laravel is a popular PHP framework created by Taylor Otwell (who, as some posts in the thread pointed out, drives a Lamborghini and may or may not wear extra-deep V-neck shirts). The Laravel framework is designed to make web development tasks, like authentication, routing, and caching, easier and more accessible via abstraction layers. Its fans love it because easy to learn. But simplicity isn't always what new devs need; what they really need is more debates on Reddit.
My Two Cents
I never used Laravel, so I have no horse in this particular race. But it seems like Laravel has a lot of "magic under the hood", and this can cause confusion for inexperienced developers. In my programming classes I like to tell students that it's okay to blackbox some concepts for now, especially if it's done for the sake of being able to make progress. But come back to the blackboxes when you've got a better grasp of the big picture. If we blackbox everything, what are we actually learning?
Abstracting complexities can lead to less-than-optimal code. I'll be the first to admit that I've been guilty of this myself in the past. It can also lead to misconceptions about the language as a whole. I'm a fan of making PHP and any programming language accessible, and even throwing in some training wheels as needed. But don't structure the learning experience so that juniors don't know the difference between the abstractions and the underlying principles.
Laravel's Place in the PHP Ecosystem
If it's a powerful tool that can open the language up to more devs, then that's a good thing. As long as juniors are never led to believe that they are learning Laravel. No, you're learning PHP and you need to focus on the fundamentals and best practices. Don't think that your learning journey begins and ends with any framework or platform. The spirit of "lifetime learning" is what will propel you to a career with tons of opportunities.