Sites for WordPress tutorials are nearly a dime a dozen. Some are fantastic, and others leave us wanting more. I know their ultimate goal is to help other people learn how to write plugins the right way, but it’s a mixed bag when it comes to the quality of the content.

  • Are you learning the best practices?
  • Are the concepts being presented done so in a way that’s accessible via beginners and intermediates alike?
  • Are they promoting practices as outlined in PHP best practices and WordPress best practices?

There’s nearly an endless permutation of how we can present information which is why I enjoy sharing my take on things here, reading the comments, sharing content on other sites.

But one aspect of WordPress tutorial sites that is underserved, in my opinion, is talking with people who build things for WordPress and the reasons for creating a solution and the rationale behind how they’ve built it. This is something that can be covered both about WordPress themes and WordPress plugins.

Because I spend the majority of my time working on WordPress plugins, I’m obviously going to be focused more on that aspect of the economy than the other. And recently, a friend of mine started up a new site specifically geared towards WordPress tutorials focused on plugins.

The site is neat, though: It’s not like a music review site that aims to provide a rating or end-user review of a plugin. It’s something different, and I’m a fan.

Read More

/ June 23, 2016 / Comments Off on What Are Code Smells?

What Are Code Smells?

There are a lot of fun terms, like “code smells,” that come up in programming. And though they may have unusual names and make somewhat tedious or boring concepts sound a little more exciting, they can often refer to something that decreases the quality of what we’re building.

At least, that’s the case with code smells.

In a previous post, I’ve talked about using PHP CodeSniffer to watch the code we’re writing to help us make sure that we’re following certain standards, rules, and what not but I’ve not discussed it regarding code smells.

Read More

As much as I love how easy it is to create a project on top of WordPress and release it into one of the free repositories, there are certain aspects of development that are neglected.

Case in point: testing.

And though I’ve been talking a little bit about unit testing, there are also other types of testing such as acceptance testing, integration testing, black-box testing, and so on.

Black-Box Testing WordPress Projects

This is not the type of black-box I had in mind.

All of the above are ways that we can go about ensuring a high degree of quality is built into our projects. Sometimes, I think we forgo these things for the sake of shipping something more quickly.

Other times, I think that we neglect to do them because writing tests is not as much fun as actually building a project. In other cases, I think that we opt not to test because we don’t have the proper education around the tooling for how to do so.

Don’t get me wrong: I have a much better track record of writing tests around client projects that I do about some of my public plugins (save for Easier Excerpts and Scheduled Post Shortcut which are done by Eric and myself), so I’m working to change that.

But if you don’t do any other type of testing, I urge you to at least try to introduce black-box testing into your development process.

Read More

Those who have worked in object-oriented programming languages are likely familiar with namespacing and the benefits they provide when organizing a project. Unfortunately, namespaces in WordPress aren’t something that I’ve seen as much as in projects I’ve seen elsewhere.

Namespaces in WordPress: File Organization

And when I say “namespaces in WordPress,” I’m not talking about WordPress core. I’m talking about WordPress plugins. I think there are a variety of reasons developers don’t use namespaces (and may I’ll talk about those later); however, I’ve gotten curious about those who do use namespaces in their projects.

Specifically, I’ve been interested in the conventions that people follow, how they map their files to their namespaces, and so on.

Though there’s likely variation in some of the things we do, I think making sure our files map to a particular directory structure is helpful when dealing with projects (especially large projects).

Read More

/ June 20, 2016 / Comments Off on Start Here for the Aspiring WordPress Developer

Start Here for the Aspiring WordPress Developer

Earlier this year, I launched a closed-membership site, The First Version, aiming to help the aspiring WordPress developer.

Ultimately, the goal of the site was not to teach in-depth concepts such as PHP, object-oriented programming, or how to create themes or plugins.

Instead, it was meant to give budding developers a survey of the landscape of WordPress development and what tools, resources, and options they have at their disposal for starting on their journey.

Given the feedback, response, and membership, I think it went well. But it’s been closed for a few months. After an exercise in re-branding and a refocusing of the content, I’m relaunching the site for another few months.

Read More