Skip to Content
What React Is and Why It Matters
book

What React Is and Why It Matters

by Eric Baer
August 2018
Intermediate to advanced
61 pages
1h 12m
English
O'Reilly Media, Inc.
Content preview from What React Is and Why It Matters

Chapter 3. React’s Primary Innovations

React’s outward messaging—and in particular, its website—is mainly aimed at developers. Its home page is full of code samples, and it explains the library in terms of its component model and its declarative syntax. In terms of React’s contributions to the JavaScript community, these things have been transformative, but ultimately both are superficial. React is very different from the libraries and frameworks that came before it, and it provides three primary innovations that, when taken together, account for why people are so enamored with it: the virtual DOM, functional patterns, and one-way data.

Virtual DOM

Rather than make changes directly to a part of a UI, applications written with React send updates to a rendering engine to make changes on their behalf.

The operation of React’s rendering engine is divided into three steps. When it receives a request to change the UI, it first determines what the new UI will look like. It then calculates the difference between the new UI and the present state. This process of diffing, or reconciliation, is made possible because React keeps a small, intermediate representation of the fully rendered app, called a virtual DOM, in memory. Finally, React estimates, from this diff, the most minimal and performant set of updates to make to the UI.

To explain how this works and why it’s important, here is a quick refresher on the way web applications work. Everything on the web, from Wikipedia to YouTube, ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

Beginning React

Beginning React

Andrea Chiarelli
The React Workshop

The React Workshop

Brandon Richey, Ryan Yu, Endre Vegh, Theofanis Despoudis, Anton Punith, Florian Sloot, Daniel Bugl, Brandan Jones, SudarshanReddy Kurri, David Parker, Cihan Yakar
Test-Driven React

Test-Driven React

Trevor Burnham

Publisher Resources

ISBN: 9781491996744Errata Page