Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SuspenseList Optimizations #16005

Merged
merged 6 commits into from
Jul 1, 2019

Commits on Jul 1, 2019

  1. Add a bunch of optimizations to SuspenseList

    We now are able to bail out of reconciliation and splitting out the tail
    during deep updates that hasn't changed the child props. This only
    works while the list wasn't suspended before.
    
    I also moved the second render of the "head" to the complete phase. This
    cleans it up a bit for the tail collapsing PR.
    
    For this second pass I also use a new technique of resetting the child
    Fibers for the second pass. This is effectively a fast path to avoid
    reconciling the children against props again.
    sebmarkbage committed Jul 1, 2019
    Configuration menu
    Copy the full SHA
    1b74a41 View commit details
    Browse the repository at this point in the history
  2. Move to didSuspend from SuspenseListState to the effectTag

    The effectTag now tracks whether the previous commit was suspended.
    
    This frees up SuspenseListState to be render-phase only state.
    
    We use null to mean the default "independent" mode.
    sebmarkbage committed Jul 1, 2019
    Configuration menu
    Copy the full SHA
    9842cae View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    55e8697 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    699ecb6 View commit details
    Browse the repository at this point in the history
  5. Add optimization to bail out of scanning children if they can't be su…

    …spended
    
    This optimized the deep update case or initial render without anything
    suspending.
    
    We have some information available to us that tell us if nothing has
    suspended in the past and nothing has suspended this render pass.
    
    This also fixes a bug where we didn't tag the previous render as having
    suspended boundaries if we didn't need to force a rerender.
    sebmarkbage committed Jul 1, 2019
    Configuration menu
    Copy the full SHA
    be3e675 View commit details
    Browse the repository at this point in the history
  6. rm printChildren

    oops
    sebmarkbage committed Jul 1, 2019
    Configuration menu
    Copy the full SHA
    ea6d36c View commit details
    Browse the repository at this point in the history