Make your code simpler to read and simpler to debug by breaking apart your conditional statements and exiting the function whenever possible. This helps to: make your code simpler ensure your functions have one purpose keeps your functions smaller makes your code easier to read makes your code easier to debug
Did you know you can not only use Composer to manage dependencies, but actually develop a package alongside your dependencies? It’s called –prefer-source and boy is it neat. The gist of it is this: you define a repository and require the package as you would for a normal dependency, but when you go to run […]
Problem Difficult to modularize code and maintain separate repos. Submodules are difficult or problematic to use. Solution Git Subtrees allow you to track and update a repo within a repo without the headache of submodules. For a more in depth read on what / why – check out Vinicius’ awesome article. Setup 1. Add remote […]
When working with caching strategies, it’s important to step through your invalidation strategies. Namely, thinking through at what point does the data that you’re caching get regenerated, how does it get regenerated and who is regenerating it. It could be regenerated any time a new post is published, on a save_post hook by an author or […]
Recently I ran into an issue where an installation of WordPress that had never had any issues updating stopped being able to update via the admin update button. These three commands fixed the issue.