Chapter 2. React: A History

Facebook filed for an initial public offering (IPO) on the first of February in 2012, which means that by mid-2011 the US Securities and Exchange Commission (SEC) paperwork was in full swing and Facebook’s Ads platform was the official center of Facebook’s financial future. The Facebook Ads code was written using a technique called two-way binding, whereby data is linked to parts of a UI such that changes to one are immediately reflected in the other. Two-way binding was a common technique at the time and was promoted heavily in libraries like Knockout.js and AngularJS, but large applications were beginning to struggle with its complexity. For cases in which the UI is connected directly to the data, the concept is simple to follow: a page that displays a view counter connects, or binds, to a piece of data called viewCount, for example. The problem is that most applications also need sophisticated compound data that can trigger cascading, interrelated updates.

As the Ads application grew, it became difficult to understand the exact series of events that caused a specific piece of UI or data to change, to recreate those events, and to make targeted fixes to bugs. Some of the code to manage these problems was released as open source, but given the persistent problems at Facebook, and that tools like Ember.js and AngularJS were doing similar things, the adoption was lackluster.

I was sort of a framework connoisseur. I guess that’s what started this.

Get What React Is and Why It Matters now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.