I have developed my own WordPress theme based on the Roots starter theme. Because of my clients needs, I'm often required to develop custom features (what I refer to as "modules") that are added to the core: for example a "Projects" custom post type, a "Business Hours" page in the admin, or a custom "Slider" menu, etc.
There's a couple reasons why I decided to code these modules and extend the theme instead of using existing plugins:
- It's a great way to learn WordPress
- I need to bundle and activate the modules dynamically in every new projects
- I don't want the clients to be able to deactivate the features (unlike plugins)
- I don't want to rely too much on third-parties
- For consistency matters, I like if the code is similar everywhere
- Flexibility: from my experience home-made modules are often easier to understand, maintain, and improve in the future
I do however understand that building my features as plugins would brings a better code separation and have it's benefits.
So here's my question: Should I keep building and adding the new features directly to the theme, or develop them as plugins instead? What is the best approach based on your knowledge and experience?
Any input or documentation would be very appreciated. Thanks!