Tagging sample sections.

master
Thomas Hintz 4 years ago
parent 08d5fdfbee
commit 5808343b61

@ -19,7 +19,7 @@
#+options: toc:nil tags:nil #+options: toc:nil tags:nil
* Preface :frontmatter: * Preface :frontmatter: :sample:
:PROPERTIES: :PROPERTIES:
:EXPORT_FILE_NAME: manuscript/preface.markua :EXPORT_FILE_NAME: manuscript/preface.markua
:END: :END:
@ -52,10 +52,9 @@ you better understand how it works, and even more critically, it will
allow you to play with it and test how the algorithms work with your allow you to play with it and test how the algorithms work with your
own examples. own examples.
Even if you don't write out the code yourself and,instead, read through this Even if you don't write out the code yourself and, instead, read
book more like a novel, I believe the through this book more like a novel, I believe the fundamentals will
fundamentals will still stick with you and provide value in your still stick with you and provide value in your React programs-to-come.
React programs-to-come.
I'm very excited to take you on this journey with me and, so, now it's time I'm very excited to take you on this journey with me and, so, now it's time
to learn what lies at the very foundation of React. to learn what lies at the very foundation of React.
@ -346,7 +345,7 @@ of ~elements~ (surprise).
That's it. Now we have everything we need to actually begin the That's it. Now we have everything we need to actually begin the
process of rendering our tree to the DOM! process of rendering our tree to the DOM!
* Render: Putting Elements on the Screen * Render: Putting Elements on the Screen :sample:
:PROPERTIES: :PROPERTIES:
:EXPORT_FILE_NAME: manuscript/render.markua :EXPORT_FILE_NAME: manuscript/render.markua
:END: :END:
@ -737,12 +736,12 @@ decide how and when to render components are the same. And, when not
running in Concurrent Mode, the effect is still the same, as React running in Concurrent Mode, the effect is still the same, as React
still does the render phase in one block. So, using a simplified still does the render phase in one block. So, using a simplified
interpretation that doesn't include all the complexities of breaking interpretation that doesn't include all the complexities of breaking
up the process in to chunks enables us to see more clearly how the up the process into chunks enables us to see more clearly how the
process works as a whole. At this point, bottlenecks are much more process works as a whole. At this point, bottlenecks are much more
likely to occur from the underlying algorithms and not from the Fibers likely to occur from the underlying algorithms and not from the Fibers
specific details. specific details.
* Putting it all together * Putting it all together :sample:
:PROPERTIES: :PROPERTIES:
:EXPORT_FILE_NAME: manuscript/putting-it-all-together.markua :EXPORT_FILE_NAME: manuscript/putting-it-all-together.markua
:END: :END:

@ -1,4 +1,3 @@
frontmatter.txt
preface.markua preface.markua
acknowledgments.markua acknowledgments.markua
mainmatter.txt mainmatter.txt

@ -2,6 +2,6 @@
The actual React implementation used to look very similar to what we've built so far, but with React 16 this has changed dramatically with the introduction of Fibers. Fibers is a name that React gives to discrete units of work during the render process. And the React reconciliation algorithm was changed to be based on small units of work instead of one large, potentially long-running call to `render`. This means that React is now able to process just part of the render phase, pause to let the browser take care of other things, and resume again. This is the underlying change that enables the experimental Concurrent Mode as well as runs most hooks without blocking the render. The actual React implementation used to look very similar to what we've built so far, but with React 16 this has changed dramatically with the introduction of Fibers. Fibers is a name that React gives to discrete units of work during the render process. And the React reconciliation algorithm was changed to be based on small units of work instead of one large, potentially long-running call to `render`. This means that React is now able to process just part of the render phase, pause to let the browser take care of other things, and resume again. This is the underlying change that enables the experimental Concurrent Mode as well as runs most hooks without blocking the render.
But even with such a large change, the underlying algorithms that decide how and when to render components are the same. And, when not running in Concurrent Mode, the effect is still the same, as React still does the render phase in one block. So, using a simplified interpretation that doesn't include all the complexities of breaking up the process in to chunks enables us to see more clearly how the process works as a whole. At this point, bottlenecks are much more likely to occur from the underlying algorithms and not from the Fibers specific details. But even with such a large change, the underlying algorithms that decide how and when to render components are the same. And, when not running in Concurrent Mode, the effect is still the same, as React still does the render phase in one block. So, using a simplified interpretation that doesn't include all the complexities of breaking up the process into chunks enables us to see more clearly how the process works as a whole. At this point, bottlenecks are much more likely to occur from the underlying algorithms and not from the Fibers specific details.

@ -1,4 +1,5 @@
# Preface {sample: "true"}
# Preface :frontmatter:
Welcome to *Foundations of High-Performance React Applications* where we build our own simplified version of React. Well use our React to gain an understanding of the real React and how to build high-performance applications with it. Welcome to *Foundations of High-Performance React Applications* where we build our own simplified version of React. Well use our React to gain an understanding of the real React and how to build high-performance applications with it.
@ -10,7 +11,7 @@ And while this book only specifically addresses React-DOM, the foundations apply
The code in this book is clear and simple so as to best communicate the algorithms well be exploring. It is not intended to be used in production, but it is functional. I think youll likely find it useful to follow along by writing the code yourself. It will help you better understand how it works, and even more critically, it will allow you to play with it and test how the algorithms work with your own examples. The code in this book is clear and simple so as to best communicate the algorithms well be exploring. It is not intended to be used in production, but it is functional. I think youll likely find it useful to follow along by writing the code yourself. It will help you better understand how it works, and even more critically, it will allow you to play with it and test how the algorithms work with your own examples.
Even if you don't write out the code yourself and,instead, read through this book more like a novel, I believe the fundamentals will still stick with you and provide value in your React programs-to-come. Even if you don't write out the code yourself and, instead, read through this book more like a novel, I believe the fundamentals will still stick with you and provide value in your React programs-to-come.
I'm very excited to take you on this journey with me and, so, now it's time to learn what lies at the very foundation of React. I'm very excited to take you on this journey with me and, so, now it's time to learn what lies at the very foundation of React.

@ -1,3 +1,4 @@
{sample: "true"}
# Putting it all together # Putting it all together
Now that we've explored how React renders your components, it's time to finally create some components and use them! Now that we've explored how React renders your components, it's time to finally create some components and use them!

@ -1,3 +1,4 @@
{sample: "true"}
# Render: Putting Elements on the Screen # Render: Putting Elements on the Screen
There are now only two major puzzles remaining in our quest for our own React. The next piece is `render`. How do we go from our JSM tree of nodes to actually displaying something on screen? We do this by exploring the `render` method. There are now only two major puzzles remaining in our quest for our own React. The next piece is `render`. How do we go from our JSM tree of nodes to actually displaying something on screen? We do this by exploring the `render` method.

Loading…
Cancel
Save