Skip to main content

Matt Smith

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

Why I don't chain everything in JavaScript anymore

2 min read
0 views

I used to write a lot of JavaScript like this: const result = users .filter(user => user.active) .map(user => user.name) .sort() .slice(0, 5); Nothing here is wrong. I wrote code like this all the time. But this is exactly the kind of thing that feels fine at first, then slowly...

  • JavaScript

You probably don't need to lift state

1 min read
618 views

This comes up a lot, and it’s easy to get wrong. It’s really easy to default to “lift state up” in React. I’m guilty. But that’s not always the right move. Quick rule of thumb Keep state as close as possible to where it’s actually used. Lift it when: Multiple...

  • React

Native JSON modules are finally real

3 min read
1949 views

For a long time we got used to writing this: import config from "./config.json"; It looked like native JavaScript module syntax. But it wasn’t. Your bundler stepped in at build time, read the JSON file, turned it into a JavaScript module, and made it feel native. The browser itself wasn’t...

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