Skip to main content

Matt Smith

  • About
  • Contact
Modern Web Engineering, Front-End First

From instanceof to Error.isError: safer error checking in JavaScript

3 min read
0 views

For a long time, JavaScript developers have relied on instanceof to figure out, “Is this an error?” err instanceof Error // true...usually In normal code, that works fine. You rarely think about it. But once values come from other realms, things get weird, and the failures are silent. Everything “works”...

  • JavaScript

Explicit resource management in JavaScript

3 min read
2656 views

Writing JavaScript that opens something (a file, a stream, a lock, a database connection) also means remembering to clean it up. And if we’re being honest, that cleanup doesn’t always happen. I know I’ve missed it more than once. JavaScript has always made this our problem. We reach for try...

  • JavaScript

Stop turning everything into arrays (and do less work instead)

3 min read
10649 views

Most front-end code processes data long before it ever hits the screen. We fetch a list, tweak it, trim it down, and repeat. And usually without thinking too hard about how much work we’re doing along the way. For years, modern JavaScript has pushed us toward a familiar pattern: data...

  • JavaScript
Older posts
Twitter
LinkedIn
GitHub
CodePen
© 2026 Matt Smith. All rights reserved.