There is mounting excitement over the WP REST API being added to core and rightly so! It is going to fundamentally change the WordPress landscape and open up all sorts of new possibilities. Developers are drooling over all the cool stuff they are going to be able to build. Exciting times! But… When it comes to using the REST API with themes, it may not always be the best choice. TLDR If you’re building themes for your own site or for a large client with a dedicated web team, go knock yourself with all the coolness you can build with the REST API. If you’re building themes that will be distributed or will be used by small to medium clients that don’t have dedicated support, then you need to ask yourself if using the REST API is really the best thing for your users. Chances are you’ll be making their lives harder. Note: I’m not talking about standard themes that just use the REST API for Ajax requests. That’s fine. I’m talking about themes that do things radically differently. Background I’ve been writing this post for more than a year. It started off as a post about why using Twig/Timber in distributed WordPress themes may be problematic, but the same issues exist for the REST API too.
Share This