dillon1000/react

Commit

Remove most comments from HTML generation output (#10029)

Simplifies markup generation by only inserting a simple comments between
consecutive text nodes.

I also skip past comments and other nodes while hydrating. This leaves them
in place instead of being removed by the hydration mechanism. This is more
efficient but will also be needed by hydration validator.

There's a special case for empty strings. We probably shouldn't have nodes
for those at all. For now I special case it by assuming there won't be one
so if we need one, we'll insert an empty text node.

I also dropped the ID from the react ID.
Browse files
Changed paths6 files
First-parent comparison
M src/renderers/dom/fiber/ReactDOMFiberEntry.js ModifiedM src/renderers/dom/shared/__tests__/ReactDOMServerIntegration-test.js ModifiedM src/renderers/dom/shared/__tests__/ReactServerRendering-test.js ModifiedM src/renderers/shared/fiber/ReactFiberHydrationContext.js ModifiedM src/renderers/shared/fiber/ReactFiberReconciler.js ModifiedM src/renderers/shared/server/ReactPartialRenderer.js Modified
Patch

Files changed

Rendering syntax-highlighted changes…