Nick Ang profile picture

Nick Ang

Want to see a full list instead of pages of results? Click here.

Write quicker tests with console.assert and blocks

Apparently can be interpreted by the JavaScript engine as a block and not an object. That’s the first learning. The second learning is that the built-in object has an method that you can use for super simple and quick testing. The method signature is . Combine these two learnings and you have…


What the duck is Duck Typing?

Boiled down to a sentence: it’s the choice of invoking a method based on whether something has the method, rather than based on whether something is of a certain type. Use duck typing when you care more about what something can do instead of what something is. For example, if you have a variable of…



Counting up in Binary

Not knowing how to count up in binary is not a big deal. But it is nice to know the ground you're standing on as an application developer!





How to implement an LRU cache in JavaScript

LRU = least recently used. An LRU cache is supposed to have a maximum size and when the user tries to insert the (max+1)th item, it is expected to evict the least recently used key-value pair to make space for the new insertion. All requirements: When the max size is hit, and an item is being…



Technical or not, the hardest part of blogging is still writing

This blog is run on Gatsby.js, a decision I made 1.5 years ago and haven’t looked back on. Well, until recently. I’m not planning to change the CMS behind this blog any time soon (who has time for that after only less than 2 years?), but I do want to pause and reflect on this idea of a Technical vs…


Why I'm active on Instagram again

I started to use Instagram again, prompted by the entry of my daughter into my life. Before becoming active on IG this time, I had left the platform for a year and a half because I didn’t like the person I was becoming as I used it. Whenever I posted, I pegged too much of my self-worth to the…


What I learned asking 120 people about my writing

About a week ago I sent out a letter to my subscribers asking them to tell me one question: Why are you subscribed? I wanted to find out what kind of people were on the receiving end of my nascent personal newsletter: What drew them to subscribe? What did they like so far from reading the newsletter…


Stop thanking me for what I ought to be doing as a father

This is going to sound utterly self-congratulatory, but it’s rather the complete opposite. Since our daughter was born a little over a month ago, I’ve received messages from a few people saying how happy they were to see that I’ve been a present father. For example, our midwife said to me, “it’s…


Employment sweet spot

Symbiosis comes from overlapping competitive advantage, true motivation, and impact for the businesses.


Specialist or Generalist?

A nice & warm batch brew. Mmm… I realised something this morning when buying coffee at my local café — the person who pumped the batch brew coffee into my mug was not the barista, and she didn’t pre-heat my mug with hot water before pumping coffee into it. It didn’t bother me much; it was simply…



The newborn bubble

I have an apartment with a roof and plumbing and this is the bubble I have lived in for the last two weeks since my first child was born. A newborn bubble. I don’t sleep much and I don’t do very much other than feed, carry, coax, assist in burping, changing diapers, launder, cook, wash, eat, and…


Retreat

I'm retreating from social media.


9 Questions for 1-1s

We all know 1-1s are useful, but not everyone sees it that way. Here is a list of 9 questions that may help guide and make your next 1-1 more useful.