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).
- Prenestation and Interaction
- Data / Server Communiaction
- Application State
- Setup
- Did any of the responsibilities that she lists surprise you?
- Do you feel like you mentally split your client side code in IdeaBox and other past projects into these responsibilities? So far I don't feel as though I thought about any of these principals. I was focused in getting things to work that I wasn’t aware of implementing these principals.
She also mentioned some guiding principals.
- use constructors to crate instances
- support configurability
- keep methods simple
- don’t intermingle responsibilities Still reslly learning about what some of these are and how to apply them. We used constructors to create instances in our project, We've been learning about intermingling responsibilities since day 1 in mod 1, as well as keeping methods simple but I don't really fully understand support configurability.
Step Four: Totally Optional: take a look at some of the other forks and comment if the spirit moves you.