Bug/contstructor props - #6
Merged
Merged
Conversation
developit
added a commit
that referenced
this pull request
Dec 3, 2015
Pass `props` through Component constructors (fixes #5)
marvinhagemeister
pushed a commit
that referenced
this pull request
Mar 15, 2022
…nder()`. Fixes #6. Thanks @mikestead!
JoviDeCroock
added a commit
that referenced
this pull request
Aug 7, 2026
Every normalization branch in the loop wrote through `newParentVNode._children[i]`, reloading the property each time. Bind it once and write through the local instead. -5 B brotli (4582 -> 4577), performance-neutral across update, mount, keyed-reorder and hydration benchmarks. This replaces the earlier "avoid allocating arrays for single children" approach from this branch. Passing the single child unwrapped did win 3-7% on update10th1k, but it cost ~3% on first-paint hydration, so it was dropped. For the record, hydrate1k's reported 45-55% regression on that earlier version was a measurement artifact, not a throughput regression: the benchmark does exactly 5 warmup hydrations and times the 6th, and each iteration clones and discards ~8000 DOM nodes, which produces a deterministic periodic slow hydration every ~4-5 iterations. Each build has its own phase. Timing only #6 sampled the patched build's slow phase. Holding the build pair fixed and varying only the warmup count gave -16.8% / +30.8% / +6.4% / +0.9% / -21.8% / +7.0% for hydrations 5-10 (mean ~+1%), while a main-vs-main control over the same protocol stayed flat at +0.2% / -0.5% / -1.3%. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #5 :)