Skip to content

Nested Render Trees #3210

@sebmarkbage

Description

@sebmarkbage

The way we implement portals is through a nested React.render in componentDidMount/Update. This is also how react-art can switch render mode in the middle of the tree.

This comes with a few problems.

  1. We can't reason about the depth of a component. Which is why we had to implement mountOrder.
  2. We can't reason about its position in the tree for debugging purposes (react-devtools).
  3. We can't pass the context through to the next subtree.

We should have a first-class concept of nested render trees, that can optionally use a different render mode.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions