- Plugin Thoughts Episode 1: Making Your Plugins More Extensible
- Plugin Thoughts Episode Two – Use Filters for Plugin Text
- Plugin Thoughts Episode 3 – Don’t Forget About Core Functions
- Plugin Thoughts Episode 4 – Learn How Core Does It
- Plugin Thoughts Episode 5 – Take Responsibility for Your Products
- Plugin Thoughts Episode 6 – Contribute to the WordPress Codex
- Plugin Thoughts Episode 7 – Remember Core CSS
- Plugin Thoughts Episode 8 – Create Clean Code
- Plugin Thoughts Episode 9 – Write Better Code; Release Better Plugins
At times I am surprised by the poor quality of code that I see laying around in WordPress plugins and themes, and I don’t just mean poorly written (in terms of efficiency and functionality). In this case, I am specifically referring to the quality of code formatting.
You do not have to be a master developer to create clean code, you only need to know how to use the space bar, tab key, and the return key. It does not take more than a moment to properly format your code (including indention), but it will literally save you hours (on large projects) when you have to look back over your project.
Which do you think is easier? Finding a bug in code that is extremely poorly formatted, possibly including poor file / function names, or finding a bug in code that is clean, well laid out, and formatted properly? Unless you live in a very backwards world, you will of course find the second scenario easier to debug.
Have a listen to the episode below.