Recent Posts
In my last post, I explained how to use ECMAScript 6 proxies to throw an error when a non-existent property is read (rather than returning undefined). I came to realize that proxies allow a transparent way to augment objects with validation capabilities in an almost limitless fashion. After some experimentation, I discovered that it’s possible... […]
This past week I spent an hour debugging an issue that I ultimately tracked down to a silly problem: the property I was referencing didn’t exist on the given object. I had typed request.code and it should have been request.query.code. After sternly lecturing myself for not noticing earlier, a pit formed in my stomach. This... […]
Your product owner comes to you with a request, and suddenly your stomach is tied in knots. There’s something about the request that doesn’t sit right. You blurt out, “well, that’s a lot of work,” because it’s the only thing that comes to mind. “Well, it’s really important,” comes the response. Inevitably, some uncomfortable conversation... […]
As best I can recall, it all started around 15 years ago. I was finishing up my sophomore year at college and had just taken my last final exam. The following Monday I would be heading into the hospital for some diagnostic tests related to persistent and as-yet-undiagnosed digestive issues. I woke up on Sunday... […]
For almost two years, I’ve been keeping notes on the side about ECMAScript 6 features. Some of those notes have made it into blog posts while others have languished on my hard drive waiting to be used for something. My intent was to compile all of these notes into a book at some point in... […]
At the beginning of last year, I released my first self-published ebook, The Principles of Object-Oriented Programming in JavaScript. I decided to go this route for a few reasons, not the least of which being I didn’t really know how much time I’ve have to commit to its writing, so I didn’t feel comfortable being... […]
I’ve recently been working on a project involving Google Spreadsheets. My goal was to store data in the spreadsheet using a form and then read the data from that spreadsheet using a Node.js application. Having no experience with Google web services, I ended up digging through a lot of documentation only to find that there... […]
I’m very proud to announce that Principles of Object-Oriented JavaScript is now shipping! For frequent readers, this book is the print version of my self-published ebook, The Principles of Object-Oriented Programming in JavaScript, which I published at the beginning of 2013. Birth of an ebook The whole process began after a chat with Kate Matsudaira.... […]
I’ve spent the last few months digging into Node.js, and as usual, I’ve been keeping tabs on patterns and problems that I’ve come across. One problematic pattern that recently came up in a code review was the use of process.exit(). I’ve ended up finding several examples of this, and I’m prepared to go so far... […]
Last week I came across an article1 by Nick Fitzgerald in which he described an approach for creating private instance members for JavaScript types using ECMAScript 6 weakmaps. To be completely honest, I’ve never been a big proponent of weakmaps – I thought there was a loss of fuss about nothing and that there was... […]