Preact in pictures

Adam Solove
Apr 19, 2017 · 1 min read

I gave a talk at tonight’s ReactJS Denver meetup about Preact.

  • Part 1 describes Preact, why you might want to use it, and the tradeoffs you have to make by not using full React.
  • Part 2 walks through what Preact is doing internally to render and diff a simple application. To many people, the virtual dom and component model seem like black magic that mere mortals shouldn’t try to understand. As I hopefully demonstrated, this isn’t true. It’s a reasonably simple algorithm with a few fiddly little details. While React is implemented somewhat differently, knowing Preact’s internals is still a good first mental model for approaching it.

The video doesn’t pick up details on the slides, so you may want to view them directly. If all you want is to see the Preact algorithm diagram, a high-res version of the final state is below the video.

“Preact in pictures” talk video

The finished diagram

Diagram of the Preact algorithm

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store