10 Essential Laravel 4 Packages Everyone Should UseWeb Development
Updated on Sunday, July 6, 2014
Updated on Sunday, July 6, 2014
Laravel is a very popular and easy to use PHP framework which allows you to quickly build applications by providing a solid foundation of tools such as RESTful routing, built-in ORM, templating and much more. This means that you spend less time building the boilerplate of your application and giving you more time on writing your web application.
We’ve listed below 10 essential Laravel 4 packages which make it easier to get common functionality in your Laravel web application without having to implement it yourself. This means that you don’t have to spend a lot of time on common parts of a web application such as authentication, debugging, site optimization, etc. This list is in order of popularity, based on the number of downloads from Packagist.
One of the more common things that you do when writing web application is building new models, views, controllers and other modules. The manual work involved in doing these becomes a bit tedious. With these Laravel generators, you’ll be able to increase your productivity by simplifying that processes into a few PHP Artisan commands.
The Laravel IDE Helper package generates a file for your IDE so that it can provide you with accurate complementation. The generation is done by using the files inside your project so they are always up-to-date. Alternately, you can use a pre-generated helper file however it may not be up to date. This helps reduce the amount of documentation lookups when writing your web application.
In very simple terms, Behat is a PHP framework which facilitates the process of testing your Laravel application. It allows you to use the process of behavior driven development within your Laravel application, making it easy to write behavioral tests for your application. This is very useful if you want to follow a BDD pattern and if you find yourself more productive using that pattern.
Ardent provides self-validating smart models for the built-in Eloquent ORM of Laravel. In easier terms to understand, it allows you to define validation rules inside the models which removes the need to have them inside your views. Your views becomes much smaller and the long list of validation rules are defined in the model file, where they should belong. With this, you can easily define your models and not worry about large amount of validation in your views.
The PHP Debug bar project is a huge success in making debugging of application much easier, so that you no longer have to put
var_dump() everywhere in your code. The Laravel Debug Bar project extends the debug bar to include all sorts of other information regarding routes, views, events and much more. This makes debugging a faster and easier process, allowing you to be more productive.
In almost all web applications, there is some sort of basic authentication which involves registration, login, logout, password resets, etc. The process of writing all this code takes time, can possible lead to security problems if not properly implemented and uses up useful time which can be dedicated into writing your application. With Confide, you get all the basic authentication features you need without writing a line of code. More time writing your web application, less time writing boilerplate.
The second most popular web application feature is role based permissions. Many times, you’ll find the need to allow users of a specific role to access a feature. An example of this is having both “Administrator” and “User” roles inside of a web application. Entrust allows you to do all this without writing a full RBAC system. All you need to do is define a few roles and filter routes based on them.
Forms are everywhere in web applications. If you have any type of user interaction inside your application, it usually involves forms. However, they eventually become a pain to maintain. Former makes it much easier to define forms within PHP and render them automatically using your favorite CSS framework such as Bootstrap or Foundation. This makes maintaining your forms much easier and makes getting them done much faster.
One of the simplest and easiest ways to reduce your page size is by minifying your HTML source code. The Laravel HTML Minify package allows you to get an reduction of up to 18% of the file size without doing any changes at all except adding a provider in your application. This is such a tiny and small amount of work which results in a fairly significant improvement in performance.
An administrative interface is almost a requirement for any web application. The basis of administrative interfaces is typically very simple however it’s an extra amount of work to do that is quite repetitive. Laravel Administrator provides you with an easy to use administration interface which allows you to focus on building your web application and not on the back-end management of your website.
There is an abundance of packages to help you accomplish whatever task that you need to do within Laravel, we could never put them all together, however, a few other useful ones to mention in here are:
In conclusion, you’ll almost always find a package which solves the problem which you’re looking for inside Laravel. Therefore, it’s extremely useful to do some research before starting to write code because someone most likely has already attempted to solve the problem which you’re trying to accomplish. We hope to have covered most essential packages however if we have missed any, feel free to let us know in the comments!