php
Check out the blog for all posts.
Better alternatives to empty() in PHP
I’m working on a weekend project: a static code analysis tool for PHP, just because, well, why not? So, I’ve...
Read article →
Singleton Design Pattern in Laravel
Google search console told me that I got some visits from people searching for “Singleton Design Pattern in Laravel”. But...
Read article →
How to avoid boilerplate code in Symfony Voters
Symfony voters are the way to go when you need to centralize the authorization logic of your application. There have...
Read article →
What Symfony developers should know before using Voters
Voters are Symfony’s most powerful way of managing permissions. They allow you to centralize all permission logic, then reuse them...
Read article →
Hidden Gems in Composer Every PHP Developer Should Know
Composer is the most popular PHP dependency manager. I’ve heard about other package managers like PEAR & Phing, but I’ve...
Read article →
PHP Real-world use cases of singleton design pattern
The singleton pattern ensures that a class has only one instance and provides global access to it. Okay, many developers...
Read article →
How to test Elasticsearch in PHP applications
Starting from Elasticsearch 8.0, they introduced multiple breaking changes in the Elasticsearch client library. This article is intended to v...
Read article →
Why you need a builder to create your entities and models
Static factories and constructors share a limitation; they do not scale well to large numbers of optional parameters. Consider the...
Read article →
Three advantages of using static factory methods in PHP
Constructor overloading is a concept of having more than one constructor with a different list of parameters. PHP doesn’t allow...
Read article →