
Perfmatters, in its version 2.5.3 of November 11(Changelog), added a feature called "Code" with which you can add PHP, JS, CSS and HTML code snippets. It has been written from the ground up with performance in mind, which is why it is one of the most (if not the most) valued tweak plugins when it comes to WPO tasks.
It uses a flat file approach, which means it is more secure and there are no database calls on the front-end. This means they are served fast and do not negatively affect page load times.
It also has a built-in error checking function, which prevents bad code from breaking your site. If an error is detected in a snippet, it will be automatically disabled. And if something still breaks, it includes a Safe Mode that can be used in case of problems that are not automatically recovered by preventing code snippets from executing regardless of their active state by creating a recovery URL.

It includes a complete condition generator to load your snippets only where they are needed. You can configure an almost unlimited number of rules, add inclusions, exclusions and even have snippets loaded by user role status (logged in or logged out).

In the tool's documentation you have all its detailed options.
While I have mixed feelings when a lightweight and effective plugin starts to "bloat" with features that other dedicated plugins do well, or better, or can be solved with a bit of code to avoid installing a new plugin, in the case of Perfmatters they have my vote of confidence because the philosophy of their plugins always revolves around simplification and optimisation.
So the other night I migrated to Permatters all my PHP code that I had in the functions.php and all my CSS tweaks that I had added in the style.css of my child theme.
Although they were well commented, categorised and ordered, having them isolated, optimised and organised in a snippet management tool is a best practice to more easily and quickly attack problems or conflicts.
"Code" by Pefrmatters comes to compete with great classics such as the popular "Code Snippets", which has a very valid free version and a paid Pro version with advanced options, or WpCode, also with a free and premium version for managing snippets in the cloud.
Although the tool is still in Beta, it is already very complete and functional. I haven't found any bugs so far, apart from small aesthetic details to be polished, such as the automatic resizing of the box where the code is added. The only thing I missed was an export/import function to save a backup copy of the snippet list, but Brian Jackson, one of the developers, told me that very soon they will add a separate function for this task and that they are also working on another one to migrate snippets from WPCode.






