Skip to main content

Catching Up With The Web

It's weird and exciting to be writing again but it certainly feels like my blogging muscles have become weak and flabby from disuse. So think of these early posts here as me doing a lot of planks and crunches before committing to push-ups.

I'm probably not going to be writing many tutorials or deep-dives. I'll be deferring that to others with the time and inclination. If there's code here, it'll probably be in service of teaching myself something new and sharing it.

You Kids And Your Toys #

Have you ever looked a modern toys and felt burning jealousy? When I was young a toy dinosaur was a solid block of molded plastic. If it was multicolored, you were lucky. Today's dinosaur toys walk, roar, are multi-articulated, and some come with battle damage.

Being inside a Big Tech Company for a few years is a great way to lose sight of what's happening outside the citadel walls. Staying on top of this stuff is part of the job, but when the job focuses primarily on shipping it's common to stick with what you have that's already working. If this is you, don't feel bad. Some of the most senior devs I've worked with aren't leveraging "new" web technologies, including things that have been supported for years in most browsers, for various reasons.

I've been playing catch-up and there are a lot of really fun toys to check out.

Things I'm excited about:

Web components! #

Web components have been around for a few years but seem to be having a moment. This is probably the development I'm most excited about. Custom markup that extends existing HTML elements, which can be backed by JavaScript to add additional functionality.

I'm so on board with this. I always thought of jQuery as an excellent tool for progressive enhancement, but it wasn't often used that way, to the point where whole applications relied on jQuery to work at all. I've written a lot jQuery and React (like, a lot) and I far prefer the pattern of squeezing as much functionality our of markup and CSS as possible, then adding functionality with JavaScript after the page loads. jQuery made this easy, but it didn't enforce composability or reuse, and you needed to drag a full version of jQuery around.

Web components seem an ideal compromise, because they are JS-enhanced markup. Write the base component's minimal functionality with HTML and CSS, then decorate it with vanilla JavaScript and standardized browser APIs. Or you can throw caution overboard and write the whole component as JS, and use the custom element attributes as props. If you can resist the siren call of npm install you can pretty much reuse your component anywhere, with zero third-party dependencies!

I can't wait to try this out. I have so many ideas.

CSS advances! #

Where to begin? Container queries! Nesting without SASS! A mature CSS Grid, with subgrid on the way. Tons of pseudo-classes! Including :has() which is damn near magical.

Non-React JS frameworks! #

There are SO many. Vue, Svelte, Preact, Solid, Astro and more. Some of these have been around long enough to be mature alternatives to the React ecosystem.

JavaScript modules! #

Native JS dependency management without the toolchain. If you've been using Babel or Webpack for a few years you might not even realize that most Chromium and Webkit browsers support this now.

There's more that I could list but these are top-of-mind at the moment.