I don’t just mean theme frameworks (though they also apply). I mean any kind of framework.
Wait, aren’t these things supposed to make my life EASIER?
Well, yes, but that’s part of the problem. Frameworks like the ones I listed above are “easy mode”. They allow you to create more complicated things in a super easy way. And while that’s not necessarily a problem, it is a problem if you use it as a crutch and don’t actually learn what you’re doing.
Quite often, people just fall into a trap of relying on the framework. They don’t learn how the WordPress settings API works since the framework just does it for them. They don’t learn the underlying code. So, they would be completely lost if they had to edit, change, or add something to the framework’s functionality. They become completely dependant on the framework.
If the framework stops being developed, they’re screwed because they don’t know how to do it on their own.
The next natural step is to find a new framework to switch to, which just repeats the process. These people constantly toe around the underlying issue, which is that they can’t do it themselves.
I’ve been there
In my earlier WordPress days, the settings API seemed so confusing. I wanted to code my own themes, but I felt like I NEEDED a settings panel in order to be successful (I was influenced by Theme Forest), and yet I had no idea how to create one. So, I crawled over to frameworks, like SMOF.
My problem was that I just added SMOF to my code, added my settings, and that was it. I never moved forward. I never actually took a step towards learning what was going on, because I didn’t have to. And my development suffered because of it.
There even came a point where I bundled SMOF with a plugin (which it wasn’t intended to be used with) because I couldn’t code my own options panel well enough. As a result:
- I had to code weird workarounds to get the features I actually wanted and needed. They were extremely messy and hacky because the framework wasn’t built with that in mind and I didn’t know what I was doing.
- If I wasn’t able to accomplish something in the framework, I just passed it off as “it couldn’t be done,” when in reality it could be done—just not within the confines of that framework.
- I never actually learned what was going on under the hood.
Now fast forward a few years and I finally managed to break out of that trap. This happened when SMOF stopped being developed in favour of Redux. Well, I moved to Redux for a while but it was so massively huge and bulky (also kind of awesome, but.. bulky).
As I got more into simple, lean code, I didn’t like packing Redux with my themes. So I finally spent more time doing what I should have done all along:
- Learned the Customizer API.
- Read guides and tutorials to figure out the WordPress settings API.
- Dissected some of my favourite plugins in the WordPress.org repository to figure out how they handled settings.
And what happened after this?
- My knowledge of how WordPress actually worked skyrocketed.
- I became a better developer with leaner, cleaner code.
- I became more familiar with object oriented programming.
- I suddenly had this mindset that ANYTHING was possible. This stemmed from that first point: I knew how WordPress worked.
- My custom settings panels had better, smarter features because I knew how to create them in exactly the way I needed them.
- Because of my solid understanding of WordPress and these APIs, I was able to use frameworks if I wanted to, but this time I was armed with the knowledge of how to customize and change them.
It’s not that you shouldn’t ever use frameworks—you just shouldn’t become dependant on them
Frameworks in themselves aren’t a bad thing. Some of them are awesome and can make your job a lot faster. However, you will become a much better developer if you learn WordPress, have a solid understanding of its APIs, and then use a framework. As opposed to: using a framework because you don’t know how WordPress APIs work and then leaving it at that.
The difference between those is that with the former, you actually have a bunch of knowledge and you use frameworks to speed up your development. With the latter, you use frameworks BECAUSE you don’t have any knowledge and you don’t want to learn. If you use frameworks for that reason, you’re only boxing yourself in and limiting your own skills!