Skip to content

Instantly share code, notes, and snippets.

@stevepentler
Forked from rrgayhart/testable-js.markdown
Last active April 6, 2016 04:57
Show Gist options
  • Save stevepentler/4a349a857d5cdbd7a2d2bd39d6e373c1 to your computer and use it in GitHub Desktop.
Save stevepentler/4a349a857d5cdbd7a2d2bd39d6e373c1 to your computer and use it in GitHub Desktop.
Writing Testable JavaScript

Step One: Watch Writing Testable JavaScript - Rebecca Murphey from Full Frontal 2012 (award for worst conference name ever?)

Step Two: Fork this gist.

Step Three: Consider the four responsibilities that Rebecca lists for client side code (hint: they're color coded).

  • Did any of the responsibilities that she lists surprise you?
    • Presentation & interaction
    • Data/server communication
    • application state
    • setup No real surprises.
  • Do you feel like you mentally split your client side code in IdeaBox and other past projects into these responsibilities?
    • Definitely not. I think working specifically with a canvas has really helped me underestand the presenation and interaction portion. It's easy to follow convention with a big engine like Rails, but thinking about game time within the paradigm of "what's drawing to the canvas?" and "what isn't draing to the canvas" has been a huge shift. It'll be nice to keep these in mind when we move back to frameworks. Step Four: Totally Optional: take a look at some of the other forks and comment if the spirit moves you.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment