RSSAmplifier

Blog

Dan Lew Codes

Thoughts on life, the universe and the mystery of it all; but actually mostly just code.

blog.danlew.netRSS feed ↗15 posts

Latest posts

Obfuscated Rhythm Games

I’ve been a rhythm game fiend since my introduction to Dance Dance Revolution in the early 2000s. I spent years obsessed with DDR, took a detour into Beatmania, then played Guitar Hero / Rock Band nonstop for years. I haven’t gone deep on any rhythm games recently,

How to use Jest mocks

For better or worse, my life has become infested by Jest mocks. I come from the land of dependency injection ( I even gave a talk once !), but whenever I talk about dependency injection to JavaScript developers I get this reaction: Instead, mocking is king. Unfortunately, I’ve found Jests&

What the fuck are passkeys and why are they everywhere now?

This is a writeup of a talk I gave at Minnebar 20 . Originally, I threw in some Matrix references to make the talk more fun & engaging. Those jokes work better in person, so I’ve mostly omitted the Matrix from this writeup (though some vestiges remain). It seems

Don't Cite Unsold eBay Listing Prices

Journalists, I beg of you: please stop confusing unsold eBay listings for actual sales. I’m ticked off after seeing this Patch post about NYC MetroCards selling for $5,000 and this WSJ article about Trader Joe’s totes going for $50,000 . Yes, someone listed these items

Hacking Displate (For Fun!)

During the pandemic my weird vice/obsession became Displates (metal wall art hung up by magnets): Some of my Displates (along with other tchotchkes in my office) For me, part of the hobby was poking holes in their website. I’ve long stopped trying to give their devs heartburn,

Balatro’s Least Erratic Decks

My most recent “just for fun” project was to find the least erratic of the Erratic decks in Balatro (a poker-ish roguelike deckbuilder game). Before each game, you pick a deck that has a special power. The Erratic deck completely randomizes the ranks/suits of the cards

Fix Your Microphone

It’s likely that, at some point, you've had shitty audio during video meetings. Why? Because you don’t get immediate feedback for audio issues . With video, you can instantly see if your image is out of focus or if you’re not in the

When Your Source of Truth is Reality

Let me tell you a story about why one should be cautious with databases that track the real world. I play trombone in a local community orchestra . For the past two years, I’ve been the board secretary; part of my duties is keeping a roster of who is

Coding by Magic

Most of my programming ventures begin with a single line of code I’m curious about. Who is calling the code, and how does this code fit into the larger jigsaw puzzle? As a result, “find usages”, “go to declaration”, and “go to implementations&

Programming Priorities

Software development (or, you know, life in general) is all about juggling priorities. For this post, I’m thinking specifically about code design priorities . You only have a limited amount of time to implement a feature, so you have to pick and choose which aspects of it to spend

Dan's Edina Sample Ballot Election (2024)

As a summary, here's what I'm voting this year on my Edina, MN ballot (along with links to research on why I'm voting that way): For all partisan races (president, senate, house/state reps) - the DFL candidate . Statewide constitutional amendment - Yes . County Commissioner District

Edina City Council (2024)

Another post about local Edina politics, this time the city council race. There are three candidates for two open positions; you get to vote for two: Ryan Daye Carolyn Jackson (incumbent) James Pierce (incumbent) Carolyn Jackson Let’s get the easy one out of the way first. Jackson has

Edina Mayor Election (2024)

Continuing blogging about Edina local politics… today’s race: mayor! There are two candidates for this race: Ron Anderson Jim Hovland (incumbent) Both candidates have tenures in Edina’s government - Anderson served on the Edina city council for one term (he lost his bid for reelection), whereas

Hennepin County Commissioner, District 6 Election (2024)

I’m gonna do some more write-ups on local (Edina) elections this year. (Those of you here for software development thoughts: I'll go back to that soon.) Today’s race: Hennepin county commissioner for district 6. There are two candidates for this race: Heather Edelson

My Evolving Approach to Learning Programming Languages

I’ve recently started a new job that uses Python. The last time I professionally Python’d was 15 years ago, writing backends for mobile apps I worked on. At the time, I was still a novice developer, only a couple years out of college. While I’