LARAVEL. Neat and Classy.
Recently, I got an opportunity to work on this PHP framework called Laravel 4. This post is about my experiences with the framework.
In the beginning, I wasn’t too impressed. I had some level of experience with Yii framework and I was under the impression that this one wasn’t going to be any different either. At this juncture, it’s significant to say that this was the phase when I badly wanted to have hands on in Ruby on Rails and was following a few Reddit threads on why PHP was a failure and how RoR and Full stack JS were the future.
Then, after a week or so, I slowely started realising the leap I’d taken from Yii to Laravel and it turns out that it’s huge! I could go on and on about comparing Yii and Laravel, but that’s not what I intend to write here.
Few awesome things in Laravel
-
The entire workflow for the App routes, filters(to restrict users) and authentication/autnorisation was so neat. Everything was so structured and intuitive. All you have to do is to open routes.php and establish your routes, filters.php to write validations and checks to monitor user permission for specific routes. About, authentication, Laravel provides a default Auth provider library which is prettry extensive.
-
Package and dependency management was never easiser. With the emergence of Composer and Packagist, a lot of useful implementations are available for Laravel and they can be ready included and published in the app.
-
Laravel has made writing RESTful APIs a cake walk. No kidding. All you have to do is to identify your Resources and their end-points. Laravel provides classes that are called as Resources which have a default declaration and prototype definition for the HTTP methods GET, POST, PUT and DELETE. I just loved this.
-
Since Laravel 4 is relatively new, the community is really active. The public forum and IRC have helped me a lot.
Give it a try!
Next time you’re starting a project in PHP, consider working in Laravel. It has really redefined development in PHP. At least, I was able to notice it after coming from the Yii world. I’ll share few resources that you might find helpful.
- Laravel tips and tricks
- Laravel snippets
- Laravel- From Apprentice to Artisan by Taylor Otwell, the creator of Laravel.
- Laravel forum
This is just the tip of the iceberg, literally. Concepts like InversionOfControl and Facades are topics for a separate blog post altogether!
May the Force be with you!