It’s only recently occurred to me that I’ve been doing WordPress, PHP, and JavaScript development for a while. In the last 5-6 years, I’ve learned some best practices that are no longer the best. For example, state management — the practice of putting all of the dynamic values of your application — a user inputs to a form, the current page’s posts, etc. — in one place, was not common. Now, I can’t imagine life without all of my state in one place. When I started writing JavaScript, if I needed to know or update the value of a form […]
Interviews from WordCamp for Publishers 2018
WordCamp for Publishers is a two day conference for online publishers of any size. This year’s event was hosted in Chicago and was filled with talks about how agencies are helping publishers improve their workflow with Gutenberg, how to improve accessibility, and why paywalls may actually be good for the open web. I had a great time at the event and was lucky be able to interview many of the speakers throughout the week. We talked with Jake Goldman (10up), Chris Van Patten (Tomodomo), Jeannette Washington (Bearly Articulating), Mike Selander (Human Made), Libby Barker (Human Made), Jodie Riccelli (WebDevStudios), and […]
Getting Started With JavaScript (And How It Compares to PHP)
JavaScript has been in the news a lot lately, and for good reason. There’s a growing need for WordPress developers to “learn JavaScript deeply.” However, making the switch from PHP can seem overwhelming at first glance. In our opinion, even if PHP is your only programming language, you should find the switch to JavaScript comfortable enough to begin hacking away at a few scripts in no time. Once you understand how the basic building blocks of JavaScript are put together, you’ll have a solid grounding that will enable you to explore the more complex aspects of the language. In this […]
Advanced OOP For WordPress Part 7: Refactoring Is An Opportunity To Adopt Test-Driven Development
So far in this series on writing WordPress plugins using object-oriented PHP, I’ve focused mainly on testing. This is because a key advantage of object-oriented PHP is that it can be written in a way that is both highly testable and highly reusable. Just using classes doesn’t magically give us this We’ve also not written any code that does something practically useful. The idea is to show how to customize search via the WordPress REST API. The example plugin, at the point where I’ve left off just returns an array of WP_Posts. But, the public API for the system is […]
4 Excellent Resources for Learning JavaScript ES6
Given the growing connection between WordPress and JavaScript, there will likely be more and more JavaScript elements added to the platform over time. Therefore, the pressure to learn the language fluently is high. This can be somewhat challenging, since many older resources haven’t been revised in light of the most recent update. The answer, of course, is to focus on the resources that do look at the ES6 version of JavaScript, and ignore everything else. This may seem extreme, and there’s definite long-term value in starting from a solid foundation. For developers looking to code with the latest version of […]

1 Comment