Tomas Votruba: Introducing Symfony Flex Loader

In a post to his site Tomas Votruba introduces something that can be helpful for those working with Symfony 4 and Flex to make the "zero-setup configuration" easier to work with: effective use of the Symfony Flex Loader.

Symfony 4 and Flex is heading in direction of zero-setup configuration - no bundles, no extensions, no configuration. You already know how to get rid of Configuration. Flex now loads services instead of Extension class.

But it has an extra price, a lot of new boilerplate code in Kernel. Today you'll learn how to keep your Kernel Flex-ready and clean at the same time.

He starts with an example kernel that loads an extra directory (defined by a "custom path"). He shows how to refactor these examples to "make them small again" making use of the Flex loader package that reduces the number of lines required to accomplish the same end result.

Site News: Popular Posts for This Week (12.21.2018)

Popular posts from PHPDeveloper.org for the past week:

Security Vulnerability Announcement: Archive_Tar

A vulnerability in the Archive_Tar package has been found which potentially allows remote code execution.

A new release of the package is available which fixes this issue. One is strongly encouraged to upgrade to it by using:

$ pear upgrade Archive_Tar-1.4.4

Thanks to Fariskhi Vidyan who reported this issue.

Site News: Blast from the Past – One Year Ago in PHP (12.20.2018)

Here's what was popular in the PHP community one year ago today:

Powered by Gewgley