One of the commentaries that we often read or hear about WordPress is its “low barrier to entry” and why this is good for the web.
The counterpoint to this is that it prevents developers (or “would-be developers,” as some may say) from embracing more modern technologies because WordPress doesn’t require them.
To be honest, I’ve even seen some go as far as to say that if someone says they are a PHP developer who has primarily worked in WordPress for their career, then you should subtract, say, three years from their “real” PHP experience.
Yikes.
I see reasons for this – I’m guilty of some of the “older” practices – but does that mean that WordPress prevents us from becoming high-quality, object-oriented programmers?
Does WordPress Hold You Back?
As far as I’m concerned, the problem is pretty simple (and I have a perspective on “simple” that I’ll share in a little bit).
On WordPress Itself
First, WordPress’ commitment to backward compatibility allows us:
- make architectural design decisions,
- use outdated practices,
- and forgo embracing newer and better development techniques because of the support of older PHP versions.
But here’s the thing: It allows us to do so, but it doesn’t require that we do so.
On Hosting
Secondly, hosts support a variety of versions of PHP – some ranging from old versions of PHP up to the latest and greatest versions.
Using the latest and greatest generally means that we need to learn and to adopt some of these practices. For some, this includes namespaces and autoloading, for others it might include using composer, for others it might be learning about dependency injection or a plethora of any other practices.
The point isn’t what you learn; it’s that you learn.
In other words, if you’re someone who’s so frustrated by WordPress’ commitment to backward compatibility that it permits others to use antiquated techniques, recognize that’s not your problem and opt to embrace the newer facilities we have available.
And if your host supports the use of newer technologies, be it versions of PHP (or more), then use them.
That “Simple” Thing
Above, I mentioned that I had my perspective on handling problems that are “actually pretty simple.” Generally speaking, I think that if something is “simple” then it’s something we’d naturally do.
But when it comes to programming, that’s not always the case. And here’s what I mean: Though it’s simple to recognize the solution, it’s not simple to implement it.
For example, it’s simple to recognize that the problem with sticking to older versions of PHP prevents us from using some of the newer facilities of the language, it’s not necessarily simple to just start using them.
We have to read about them, understand them, practice them, employ them, and then figure out if we’re doing it right. This is but one reason why code reviews are important. It’s also why making sure that you’re reading the documentation, writing tests, viewing the logs, and generally using the application on your own while developing it is key when using new features of a programming language.
So What’s Holding Us Back, Really?
Ultimately, I’m of the mindset that the only thing that’s holding us back from becoming better PHP developer is not WordPress. It’s ourselves.
If we want to be high-quality PHP developers who have the same skillset and levels of experience as those who work in other areas of the industry, then we need to make sure we’re educating ourselves and working on projects that facilitate that.
Don’t let anyone or anything else stand in the way of that.