-

The “why” of writing tests
Unit testing is part of my normal development flow now. For the most part, I try to write my code in a “TDD” or “BDD” manner, meaning: I write my tests first, explaining how I want my public methods to behave, then follow it up with the actual code to make the tests pass. Years…
-

Using React stateless components for quick prototyping
When you’re building a new app using React it’s nice to start laying out all the components you’ll want to use inside the components that you’re building. Unfortunately this can be a little slow because for each new component you have to: Create a new file Import that file Include React in the file Export…
-

Re-ordering Objects in a List
In an old version of an app I wrote, I had a list of objects which were in a specific order. I wrote the app to operate using a REST API, so when you changed one of the objects, the client sent a PUT request to the server with the new data for that object…
-
ES2015 module re-exports
Today’s episode of TIL (“Today I Learned”) is: Did you know you can re-export modules in ES2015 (aka: ES6, aka: new JavaScript)? That is, you can import a module and export it again all in one line of code. Why would you want to do this? Well, first you need to know about the way…
-
New Year’s D&D
Because what else would you do to celebrate? Roll for initiative, 2016.
-

The Stonecutter Samurai
Once a year Automattic gathers all its employees together for a week of projects, learning, and adventure at an event called the Grand Meetup. This year I wrote a D&D adventure to share with my friends and co-workers, most of whom had never played a tabletop RPG before. It’s now been run seven times (four by me)…
-
Article on Game Design in JavaScript
http://www.smashingmagazine.com/2015/09/principles-of-html5-game-design/ And a bonus (linked from that article): an MDN article on 2d collision detection: https://developer.mozilla.org/en-US/docs/Games/Techniques/2D_collision_detection