Wörter

I’ve built something today, what have you done?

Posted on Jan 19 2021

This post I wrote quite a few years ago now and found in my drafts. I was thinking of deleting it but realised that in 2021, however many years later, it is still relevant so to whoever may find it useful — enjoy. For anyone who wants a blast from the past — here is me mentioning Angular 1.x and backbone as “recent” 😉


Among the various programming feeds I follow, be it Stackoverflow, r/programming, Twitter or just friends interested in getting started or improving their Javascript skills, I am constantly stumbling across the question — “what framework should I use?”. I would initially attempt (foolishly) to show my superior knowledge by exclaiming “You can’t compare Angular to React … React is just the view … all you need is Backbone … MVC is dead — long-live Flux”. With everyday that passed I added flames to the roaring debate around frameworks, build tools, pre-compilers and stacks. I don’t think I was wrong to do so either. This is a valid discussion that front-end developers must constantly have in order to learn about the good, weed out the bad and prettify the ugly. The problem is that it is not really the discussion that the original poster was looking for…

In my experience most people who are asking this question are of the junior level, probably writing one of their first ‘proper’ applications that involves changing state, bi-directional data flow and complexity beyond simple web forms. As constructive as the discussion around libraries and frameworks are to me and my peers, they detract from the real question which is — “what direction should I be going in in order to be a good programmer?

As this question is rarely asked in this way, what ensues is a call-to-arms for framework fanatics to fight their corner about why one framework will destroy the other. I’ve found it to be frightenting and genuinely disheartening to see the originally eager poster lost in the battle attempting to derive reason from madness. Enough drama Ben, get to the point…

Learn JavaScript, not frameworks

I’m not the first person to say this but this a point that often gets lost in the noise — learning frameworks is not the path to being a good developer, building applications is. My first web app was a multi-user real-time DAW built entirely with emerging (at the time) technology such as the Web Audio API and websockets and all running on NodeJS. Looking back at my code you can clearly see my progression, moving from incredibly serial code, riddled with race-conditions to nicely abstracted, resuable components that (unknowingly) resembled some of the ethos behind Model-View-* frameworks elsewhere. It wasn’t pretty but it was just JavaScript — alright, and jQuery.

The reason I look back on this so fondly is that by making mistakes and observing first-hand the problems with my less-than-perfect architecture taught me vast amounts about the core concepts of programming such as OOP, MVC, DRY and other such three letter accronyms.

That’s not to say I don’t use frameworks. I have recently used Angular 1.x and Backbone to build some web apps and smaller projects but whilst I may have got something built quickly, I learnt very little from it. Due to knowing Javascript well however, learning the next weekly framework isn’t a scary proposition. If my team decides to go all in with React or goes even further and says we need to change languages and start writing everything in Rust or Go then I’ll dig in my heels, pick a destination and start learning and building. The world of web development (and propbably generally software development) is one of constant change and if you’re willing to embrace that fact then it’s an incredibly fun and rewarding world to live in.

Practical next steps

I don’t believe in professing an anti-something opinion without offering a solid, actionable alternative so here are some steps that I took in order to get to where I am today that I would advise for any new(ish) developer looking to progress.

  1. Pick a project that you would like to make and don’t worry if its been done before

  2. Once you’ve decided on something to build break it down into smaller chunks and start writing code. Even if the first week doesn’t amount to anything and you end up ditching it all, you will have learnt so much in that process and that is incredibly valuable

  3. If you are going to use a framework then just pick one and use it. I have mostly used Angular 1.x and Backbone, both of which have plenty of discussions and tutorials to learn from. The ability to learn something new is far more important than what you know

  4. Once you have built something, look back at it critically and identify its shortcomings — this will give you pointers as to what you need to read to improve

  5. Crappy code that does something is far better than perfect code that doesn’t.

A particular favourite of mine for people new(ish) to Javascript or programming is Superherojs.com, which is nicely categorised into the various areas of interest and is a small enough collection of good stuff to avoid overwhelming someone. DailyJS is another firm favourite which sadly is coming to an end but has a lot of great posts guiding you through the various complexities that you will eventually encounter.

TL;DR

The important thing here is not to get bogged down in the weekly argument of which library or framework to use. Find something that you think would be useful or cool or silly and build it. Trip up, make mistakes, make something so awful that you’ll never want to show it to anyone, and at the end of the day look at your mess of barely functioning code and proudly say…

“I built something today, what have you done?”