PHP: Named arguments are your friends

It’s the developers who are not

Photo by Duy Pham on Unsplash

I reserve the right to break your app and I couldn’t care less.

From now on, changing the name of the argument in your package becomes a major version increase. It’s the difference between going from 2.0.3 to 3.0.0 because the argument $mandatory is now $required. Things like SemVer is what protect us from such stupid ass decisions like going from 2.0.3 to 2.0.4, and breaking a project.

Variadic parameters are awesome, but you will need

You lost the election, so move on

There are things in time that are life changing, and Named Parameters were one that happened for PHP more than a year ago. It’s seems too late to whine now. PHP is not a democracy, but everyone is welcome to have the power to vote by becoming an active maintainer. We, normal developers, are the ones that are on the other end of the stick. We are not evangelists, but mercenaries.

Graphic Designer graduate. Full Stack Web Developer. Retired Tech & Gaming Editor.