Dev

4 min read

February 27, 2022

See ways that make Laravel more popular with backend developers than Symfony framework, making it a great tool, even for beginner programmers.

When using both of these frameworks, I see five advantages of Laravel that influence its popularity.

1. Perfect documentation that’s always up to date

Laravel's documentation is just brilliant. Every framework element is described very well. Also, each element has its own use-case examples to get the best result. Better still, the documentation is rewritten with each update. The Laravel team does a perfect job at keeping their documentation up to date and makes sure that it doesn't include information about outdated elements. Certainly, there is a lot to learn from their technical writing team.

On the other hand, Symfony's documentation is written in a very selective way. There are certain aspects that are omitted and not mentioned in the text. As a result, you have to go search for answers in Google or browse the code. And the worst thing about it is that Symfony doesn't update their documentation on a regular basis. Contrary to what Laravel does, they don't edit it update from update. It has become a pattern that earned its own jokes. You can come across jokes about Symfony's documentation that the only thing that changes in it with the next version... is the number.

2. Simple data validation

In Laravel, it's easy to validate incoming data. You just create a new class that inherits from the "Request" class, define the parameters in which you expect to receive a given request and fill out the field values.

This isn't the case in Symfony at all. The most appropriate method of data validation is to create a class which will be mapped with the incoming data along with definitions of acceptable field values in the form of 'annotations'. Otherwise, you can use the built-in "validator" and define the allowed field values with "constraints". However, to make it work properly, you need to create an additional class (DTO), map the incoming data to it and then send this object to the "validator". Simple? Well, not really.

3. Manageable template engine

Laravel has its own template system called "Blade". It is a very simple and powerful system with the syntax very similar to PHP. Just calling "Blade" directives with "@" is much more readable to the eye than twig "{%%}". The symphonic "Twig" looks like a component written somewhat casually. Someone decided that the framework needs a template engine. The same person also decided that it doesn't matter how good or bad it works as long as it works at all… and guess what? It does work. You can even achieve the same things in both engines, but in "Blade" everything is just simply better.

4. ORM

Laravel has the proprietary "Eloquent" system. It's ridiculously easy to configure and get started with it, again, thanks to perfectly written documentation. Database queries are created very intuitively, and it only takes a few hours to get the hang of it all and figure out how everything works.

Symfony uses Doctrin which is a powerful tool, but it's more difficult to learn than Eloquent. Unfortunately, the documentation does not help again in understanding how to build complex queries.

5. Great comprehensiveness

After you install Laravel, you will see how much of a fully functional framework it is - you can literally write anything in it. There's no need to install any additional packages. After installation, Symfony is just a bare skeleton, and you need to install packages that will provide you with the functionality you require.

Summary

In my opinion, these are the elements that make Laravel the leader when it comes to popularity. Thanks to the great community that has been created around it, this framework is the best solution for someone who is just starting their adventure with programming.

Are you considering building custom software applications?

Do you want to work with a partner that will deliver cost-effectively and on time? Contact Score Digital to find out more about our values and development process.

Created by

Karol Ludwikowski

FULL-STACK SOFTWARE ENGINEER

Read more

Dev
10 min read
September 4, 2023

Can you build a web app in Flutter?

Explore the potential of Flutter for web development: its journey from mobile to web, key benefits, challenges, and how it stands against React and Angular. Discover if Flutter's cross-platform capabilities align with your project needs.

Dev
8 min read
May 29, 2023

React Native Mobile App Development: Pros & Cons

Understand the advantages and disadvantages of using React Native for your mobile app development project. Get insights into how this powerful framework can expedite the development process, reduce costs, improve app quality, and more.

Dev
6 min read
May 22, 2023

Advantages of Node.js for Your Next App

Explore why Node.js is rapidly becoming developers' top choice for app development. Discover its versatility with non-relational databases, an ever-growing developer community, expansive tooling, asynchronous programming prowess, handy pre-built NPM packages, and the ease of using JavaScript for full-stack development.

Dev
10 min read
September 4, 2023

Can you build a web app in Flutter?

Explore the potential of Flutter for web development: its journey from mobile to web, key benefits, challenges, and how it stands against React and Angular. Discover if Flutter's cross-platform capabilities align with your project needs.

Dev
8 min read
May 29, 2023

React Native Mobile App Development: Pros & Cons

Understand the advantages and disadvantages of using React Native for your mobile app development project. Get insights into how this powerful framework can expedite the development process, reduce costs, improve app quality, and more.

Dev
6 min read
May 22, 2023

Advantages of Node.js for Your Next App

Explore why Node.js is rapidly becoming developers' top choice for app development. Discover its versatility with non-relational databases, an ever-growing developer community, expansive tooling, asynchronous programming prowess, handy pre-built NPM packages, and the ease of using JavaScript for full-stack development.

Dev
9 min read
May 15, 2023

Why Node.js Is the Best for Creating Functions in the Cloud?

Discover why Node.js is the ultimate choice for creating cloud functions and leveraging the benefits of serverless computing. Learn about the cost-effectiveness, scalability, and simplified development offered by Node.js in building serverless applications on AWS Lambda, Azure Functions, and Google Cloud Functions. Unleash the potential of serverless computing with Score Digital.