Windmills on a autumn field

Using technology before it’s ready

Like any WordPress geek these days I am excited about WP REST API and want to use it as soon as possible, preferably sooner. Unfortunately there is a limit to what I can use at the moment and not everything is perfect. Like those windmills, slow and steady approach may be better.

WP REST API is currently at beta but I am willing to use it on my own website to show that I am staying up to date and always looking for what is next. That’s perfectly fine because at the moment. I wouldn’t use it on a client’s website unless the client insisted and we would amend the contract.

My initial thoughts were to use a framework to do the heavy lifting. I am quite close to jQuery and somewhat to React and Backbone. The latter two I know very briefly, React because I wanted to learn about frameworks and Codecademy has two courses. Backbone because it’s bundled with WordPress.

The only framework which I decided not to use was Angular. For some reason I don’t like Angular.

Since Backbone was already part of WordPress I started looking for some tutorials to get me started. Adrian Mejia wrote an interesting series of posts about starting with Backbone. Despite being somewhat older it gave me pretty good idea what I am up against.

Getting stuck

After those four posts I got stuck because I wanted to create a theme which would act as SPA but would be crawlable and the links wouldn’t change at all.

At that point I realized that that might not be possible at the moment because of routing. It is true that Google’s crawlers can access website with JavaScript and read the content. What is also true is when I use SPA theme all crawled links will be broken, or at least most of them. And this is a deal breaker for me.

What’s next?

I won’t be using frameworks for this project, except for jQuery. I might use WP REST API for comment section and may be for some other parts of the theme but not for whole. This all is OK because it makes me think what to do next with the knowledge I have gained about Backbone and React.