At HWC London yesterday, my intention was to spend a bit of time improving the display of my RSVP posts.  An example of one here:

My RSVP posts work great, functionality wise, thanks to the Post Kinds plugin (creating the post successfully sends a webmention to the event page).  However the display looks a little funky with my theme.

I get the little black disc that comes by default for anything with a post format of ‘Aside’.  Then the calendar icon, and then chunky double quotes for what the event is about.  I want to ditch the disc and put the calendar in its place.  I’m not sure about the quotes for now – I’ll see how they look once the calendar is moved.  It should also look decent on various screen sizes.  And I want to eyeball and test the microformats, just for my own interest.

I’d like to implement the feature with a spec first though, following my ongoing BDD/TDD attempts at implementing indieweb features.

Somewhere in the tests should probably be testing that the webmention is sent out correctly, but that would need some service stub (or perhaps even a second site instance?) to pick that up.  It can wait for now.

So, as per usual, most of my time went on faffing around with my development environment.  Yak shaving before getting to the good stuff.  For some reason I had some annoyingly persistent 301 permanent redirect sending to  Tried lots of various things (rebuilding the dev site, using private windows, clearing cache, ‘forgetting’ the site in my browser history), and eventually the 301 went away, but I couldn’t completely pinpoint what the solution was.

Then I got the indieweb-post-kinds plugin installing with the wp-cli command line.  I think I discovered a hard dependency of indieweb-post-kinds on the wordpress-indieweb plugin.  I’ll see if I can recreate that and then report it to David, the maintainer.

Then I started writing the Given step for the insertion of a note.  This was good at it had me looking around at the innards of post-kinds a little bit, and WordPress’ own DB structure in fact, which is good to learn about.  Slowly picking up the difference between terms, taxonomies, kinds, formats.  (Or at least picking up that there is a difference.)

Then I hunted down some handy helper methods in WPDb, including haveTermRelationshipInDatabase, which gives me what I need to set up the metadata associated with a post that turns it into an indieweb postkind.

And there I stopped.

Homebrew Website Club London December 13th 2017

Leave a Reply

Your email address will not be published. Required fields are marked *