Laravel – Is it a choice for web artisans?

Laravel Logo, A web framework in PHP.

Introduction to Laravel

Laravel – Is it a choice for web artisans? The official website of laravel says

The PHP Framework For Web Artisans

Laravel Official Website

Laravel is a modern PHP framework which requires PHP >= 7.1.3 (for Laravel 5.8). Its popularity is increasing everyday, and as we can see below, it’s is the most searched keyword among Symfony, CodeIgnitor, Yii, Zend which are also the frameworks of PHP.

Source: Google Search Trend

So, what makes the framework so famous? There are many reasons why Laravel become so famous for these which I will describe in following sections.

Complete Package

Routing

The main feature of Laravel is that, it has almost all features that are needed for developing a full stack website. Firstly, it provides better and cleaner routing. Moreover, it provides resource routing, i.e. you don’t have to worry about writing routes for different methods like GET, POST, PUT, DELETE, etc. Not only this, but also you can name the routes, so that if you want to change routes, you don’t have to replace every instance of that route in your project. For example,

// Set route name 'home' for '/home' url
Route::get('/home', 'HomeController@index')->name('home');

If you set a route as above, you can access the url as

$url = route('home');

Suppose, if you want to change the route from /home to /index, you can easily change the url without worrying anything. It is possible, because you have used named routes in your project rather hardcoding url.

In routing, Laravel provides other features like Route Groups, Route Model Binding, Fallback Routes, etc.

Controlling

Similarly, Laravel provides better controlling. Likewise, resource routing, you can create resource controllers. That is to say, it automatically creates methods inside your controller to make your job easier.

Views

Laravel uses blade template for views which is quite easier to work with. Not only default templating engine, but also it provides frontend scaffolding for Vue (default), React and Bootstrap without any hassle because laravel mix automatically manages the structure of project. Also, it is easier to add your own javascript in the project.

Authentication and Authorization

The important feature of Laravel over other PHP framework is that, it provides better security. As we know that, PHP frameworks are infamous for their security loophole. And this is not the case for Laravel till now. It provides basic authentication by a single command. Also, it provides authorization, email verification, encrytion, hashing and password reset features. Moreover, it provides authentication using social platforms. In addition to that, Laravel provides middlewares which can be used in routes, controllers and views.

Eloquent ORM

Laravel provides a powerful ORM and support of different databases. It is easier to configure database for your app. Further, it provides powerful query for inserting, updating and deleting the records. Also, the relationship is quite elegantly managed by ORM.

And More

Besides these, it also provides many features like Mailing, Helpers, Queuing, Task Scheduling, Notification, File Storage, Broadcasting, Caching. In addition to that, there are official packages available such as Telescope, Passport, Scout, Envoy, Dusk, etc.

In the same way, Laravel can act as API as well if configured. Hence, you can get API support along with server side rendering.

Are there any downsides of Laravel?

The main point is, will you use all those features in your app? I hope not. But if you want all these features, it will be worth using. Similarly, there are bugs in the framework which you won’t be able to figure out. For that, you have to slightly change your logic. Moreover, it provides many ways to do the same work, which I don’t prefer since it may cause inconsistencies in your project working with many people. Also, there are too much magic methods, which might confuse you.

Conclusion

I suggest you to use Laravel because it is one of the good frameworks available out there. As beautiful it looks, it is powerful too. So, laravel is a better choice for web artisans.

So, if you want to start developing your site on Laravel, check it out here: https://laravel.com/docs

If you want to know about Django, you can read it here: https://nepcodex.com/blog/2019/07/django-a-full-stack-web-programming-should-i-use-it/

0 0 votes
Article Rating
Subscribe
Notify of
guest
2 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Scroll to top

Send help to Morocco.

X