Home / Function/ insertDestinationClones() — react Function Reference

insertDestinationClones() — react Function Reference

Architecture documentation for the insertDestinationClones() function in ReactFiberApplyGesture.js from the react codebase.

Entity Profile

Dependency Diagram

graph TD
  1678510b_1bcd_dc77_c5cf_c593bd5a9201["insertDestinationClones()"]
  ee850b36_fc0b_9bb2_5b69_58d705aef9a5["ReactFiberApplyGesture.js"]
  1678510b_1bcd_dc77_c5cf_c593bd5a9201 -->|defined in| ee850b36_fc0b_9bb2_5b69_58d705aef9a5
  c7094660_51f6_2aa7_68b1_a12d32a1aa8a["detectMutationOrInsertClones()"]
  1678510b_1bcd_dc77_c5cf_c593bd5a9201 -->|calls| c7094660_51f6_2aa7_68b1_a12d32a1aa8a
  5da5a209_accd_7ea4_eb0a_748553ba2647["recursivelyInsertClones()"]
  1678510b_1bcd_dc77_c5cf_c593bd5a9201 -->|calls| 5da5a209_accd_7ea4_eb0a_748553ba2647
  style 1678510b_1bcd_dc77_c5cf_c593bd5a9201 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/react-reconciler/src/ReactFiberApplyGesture.js lines 1026–1042

export function insertDestinationClones(
  root: FiberRoot,
  finishedWork: Fiber,
): void {
  // We'll either not transition the root, or we'll transition the clone. Regardless
  // we cancel the root view transition name.
  const needsClone = detectMutationOrInsertClones(finishedWork);
  if (needsClone) {
    // Clone the whole root
    const rootClone = cloneRootViewTransitionContainer(root.containerInfo);
    root.gestureClone = rootClone;
    recursivelyInsertClones(finishedWork, rootClone, null, CLONE_UPDATE);
  } else {
    root.gestureClone = null;
    cancelRootViewTransitionName(root.containerInfo);
  }
}

Domain

Subdomains

Frequently Asked Questions

What does insertDestinationClones() do?
insertDestinationClones() is a function in the react codebase, defined in packages/react-reconciler/src/ReactFiberApplyGesture.js.
Where is insertDestinationClones() defined?
insertDestinationClones() is defined in packages/react-reconciler/src/ReactFiberApplyGesture.js at line 1026.
What does insertDestinationClones() call?
insertDestinationClones() calls 2 function(s): detectMutationOrInsertClones, recursivelyInsertClones.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free