Ben McCormick


Weekly Links: October 7th

Javascript & the Web

Common Mistakes with Keys in React | Li He

This was a nice summary of a topic that lots of people likely breeze over in React until it burns them. Short and informative; good stuff.

Extracting command line arguments from Node.js using destructuring | Nicholas C. Zakas

Destructuring is one of those JavaScript featurs that it’s easy to go a little crazy with. You go from not knowing it exists to writing expressions like this in a day1:

const {user:{fname:userFirstName = 'Jon', lname:userLastName= 'Smith}} = data;

That type of thing will drive the people reading your programs crazy eventually. This article provides a nice example of where destructuring shines.


Followership | Jason Wong

This is a really interesting breakdown of “follower styles”. I’ll admit I’m a sucker for 2x2 grid frameworks, but I love em because they’re powerful communication tools. I’ll be thinking about how I can use this with my team, as well as thinking about how I relate to those in authority over me.2

  1. That sets 2 variables, userFirstName and userLastName pulling them from data.user.fname and data.user.lname respectively, and defaulting them to John and Smith if they’re not defined. …obviously?



Copyright © 2012-2019 · Ben McCormick