Category: Software Development
-
Docker Desktop won’t reopen on macOS
After months of waiting, I finally received the MacBook Pro that I had ordered back in February. Thus far, it’s been a solid machine with crazy battery life, but not without it’s quirks. One recent quirk was with Docker Desktop. I had the app open and I quit it instead…
-
How to convert JSON to CSV in JavaScript
Last week we discussed converting CSV to JSON in JavaScript. This week, we’re going to talk about going in the opposite direction, converting JSON back to CSV. Similar to last week, we’re going to use the immensely popular papaparse library. As it turns out, even though it’s touted as the…
-
How to convert CSV to JSON in JavaScript
Parsing CSV data isn’t as easy as splitting the string up into individual lines, then splitting it by the delimited (in this case commas). Some of the values may have quotes around them, sometimes the values themselves have line breaks. Then there’s the potential that the data itself is malformed….
-
Tracking daily active users (DAU) with Redis
Daily active users, also known as DAU, is the number of unique users that have interacted with a website or application in a given day. We’re going to discuss how to track this metric, in a language agnostic fashion. The concepts discussed and Redis commands utilized can be implemented in…
-
How to display a JavaScript array in HTML
From time to time, I see a search query that made it to my blog that piques my interest and inspires a post. This is one such post. How does one take an array (presumably in JavaScript) and display it in HTML? Now in this day in age, I would…
-
Splitting strings and keeping the separator in JavaScript
When splitting strings, the majority of the time, I don’t care about the separator (or delimiter), just the strings that exist between it. In JavaScript, that’s very simply with .split(): ‘one,two,three,four,five’.split(‘,’); Which will yield an array of strings like this: [‘one’, ‘two’, ‘three’, ‘four’, ‘five’] Great! But if we want…
-
Downloading files in Node.js with Axios
I’ved used Axios a ton, but I’ve only ever used it to make AJAX requests. In fact, I don’t ever remember a time when I’ve needed to download a file and save it to disk in Node.js. That changed recently with a new side gig I’ve been helping out with….
-
Best way to pin TypeScript as a dependency
While I’m a pretty big fan of TypeScript, there’s some stuff that drives me up a wall. One of those things recently came to light during the release of TypeScript 4.4 on a Friday afternoon. So it was nearing both end of day and end of week, and we were…
-
Remove unnecessary files in node_modules
As the meme goes, the object with the largest mass in our universe is the node_modules directory. Generally speaking, storage is cheap, and while an unkept set of dependencies can be quite messy (and often times a security hazard), the size of your node_modules directory tends to not be of…
-
Debugging an AWS Lambda that stopped working
My wife and seed would agree that talking about AWS Lambdas are in my “big three” of things to not shut up about, along with fishing and professional wrestling. Regardless, I do love them so (both the Lambdas and the fam bam). As I’ve grown to use them more and…