If you’re attacking a problem that just isn’t coming together, stop and take a step back. The feeling of “GAH WHY IS THIS SO HARD” is a preemptive code smell, alerting you that you’re about to write bad code. My most recent TOO HARD experience was with table_print, my gem that prints objects as tables. I had Law of Demeter violations all over the place, spaghetti-coding myself into a ball I knew was not going to be maintainable.
2 min read
(Fashionably late on this one, but I think it’s an important conversation to keep having) Wall Street executives took trillions of dollars from us, and we’re justifiably angry - but it’s not entirely about the money. We are a nation of entrepreneurs, a nation of people who strive to make their lives and their neighbors' lives better, a nation who care for each other - committed to the common good. We have bonded together to lift us all up at once, achieving things together none of us could achieve individually.
3 min read
My friend recently asked me “Do you have any advice for encapsulating javascript or how to break an application into files/namespaces? Most of what I see online for javascript is hacky and not about designing for maintainability.” Turns out I do! First of all, you need jasmine and jasmine-jquery. I always thought TDD was a nice but impractical idea until I had an environment with fast tests. At Contour I had 130 jasmine tests (averaging maybe 3 assertions each) running in 500ms.
4 min read
I attended the Chicago Ruby Hack Night meetup last tuesday. The theme was IronMQ, a message queue web service. You can post/get/delete messages through a set of super simple HTTP endpoints, and they handle the tricky (or at least boring) stuff like storage, retries, etc. Honestly, I almost didn’t go. I know that exposure to new technologies is good for me, but usually I have a hard time justifying messing around with something that doesn’t relate to a bigger project (be it professional or personal).
4 min read