Your code is probably good enough

…as long as you’re willing to learn some more

Underneath the much discussed JavaScript fatigue I sense a sentiment that is common among us who spend hours of typing on keyboards to make stuff happen on the screen. The care and worry of our code being good enough. The influx of new tools, code standards and framework feels tiresome in the combination with the feeling that “everyone is doing this now” (newsflash: they don’t).

I’ve read somewhere that pictures of green nature makes us calm and more willing to read articles.

Coding is the exercise of abstract thinking to solve real problems. Because we express this in constrained syntactic language, it’s easy to get caught steering into the wall of Plato’s cave in search of the ideal and generic solution. We sense that there’s a better way to do something. An ideal way. And we strive for it.

It’s this care that makes us spend hours digging into the rabbithole of StackOverflow and retired mailinglists. It’s this worry that makes us squirm when a colleague or someone on the Internet wants to take a peek at our code. It’s this care that makes us push deadlines because “it’s not quite ready yet”. It’s this worry that makes some of us hesitate to jump on the new thing™ in the midts of all the other work we’re expected to be done with.

I get it. As a self-taught web developer who has spent years plucking at HTML, CSS and PHP in Wordpress templates, the dawn of JavaScript seemed weird, complex and, frankly, tiresome. I could use jQuery, with only a shallow understanding of how it worked. I didn’t really know what an “object” was, and was constantly confused about the idea of “callbacks”. I was used to the synchronous nature of PHP where I could follow the flow of code like a novel. My code sure wasn’t pretty, but it got the work done.

Sometimes the right tool for the job, is a tool you haven’t used yet

I even brought PHP into my thesis work within the Digital humanities and tried to use it to parse thousands of texts in order to say something about the nature of the concept of spirituality (this isn’t madness, this is the humanities!). I soon discovered that it wasn’t the right tool for the job — that is, the community of PHP programmers hadn’t spent much time on the problems I now faced. A programming community who had, though, were those in the world of Python. It was when I had to learn Python from scratch, I went from a journeyman coder to a novice programmer. And of course, learning through solving real problems is way more rewarding than any online course or training web portal. It was a jump into high water, but the jump got me way further on my thesis than continuing with PHP would’ve.

When I last year was hired as a coding interaction designer at Netlife Research, the buzz about React and Angular was already massive. By necessity I was pretty much forced to dive into JavaScript, and React proved a perfect learning environment. We chose it for a client’s project, and even though we were pretty fresh in the JS-game, we managed to solve the case. It’s certainly not the best code, but it gets the job done. In some ways our inexperience with React helped us to stay focused on the essential user tasks and on getting those right before launch. Yeah, it first felt wrong to mix HTML in JS, but it also felt good to template with real data, whilst learning a bunch generic JavaScript.

The realization of crappyness is a sign of competence

I suspect that most people who code can somewhat relate to this journey. The adventure of programming is one of trial and error, regardless if you’re on the path of design, computer science or advanced-copy-and-pasting-to-make-this-damned-website-do-something-cool-I-saw-on-some-other-website. But in the learning process we also discover that our earlier code often is crude, buggy and inexperienced. While our instinct is embarrassment, it should be reassuring, because it is a sign of competence. The more we know, the more we know that we don’t.

As coders, developers and programmers we must surpress our knee-jerk reaction to dismiss new languages, frameworks and tools just because of hype. We must embrace the fact that more often than not, new things are contributions to our community by people who has the urge to make something better, or to learn something new by making something they feel is useful. Coders who are dismissive to new things have always confounded me. Because to me, the real reward of coding is learning how stuff works. The feeling of accomplishment when you finally “get” what you are doing, and can continue on the path into the more complex, advanced and beatiful. This path though, is paved with code–that in retrospect–isn’t “good enough”.