Home / Function/ get() — react Function Reference

get() — react Function Reference

Architecture documentation for the get() function in Dominator.ts from the react codebase.

Entity Profile

Dependency Diagram

graph TD
  229919e6_9735_4317_1205_cd584725c183["get()"]
  a3f2f330_31b9_859d_961f_8583b63a07da["Dominator"]
  229919e6_9735_4317_1205_cd584725c183 -->|defined in| a3f2f330_31b9_859d_961f_8583b63a07da
  a90edee2_35a1_577c_a329_5f6319fef1d4["get()"]
  a90edee2_35a1_577c_a329_5f6319fef1d4 -->|calls| 229919e6_9735_4317_1205_cd584725c183
  1c6dc7ec_72e1_b907_d23f_94b6a80c2a2d["createControlDominators()"]
  1c6dc7ec_72e1_b907_d23f_94b6a80c2a2d -->|calls| 229919e6_9735_4317_1205_cd584725c183
  a90edee2_35a1_577c_a329_5f6319fef1d4["get()"]
  229919e6_9735_4317_1205_cd584725c183 -->|calls| a90edee2_35a1_577c_a329_5f6319fef1d4
  041ca752_10c1_3cda_1f5c_02f44a01310e["invariant()"]
  229919e6_9735_4317_1205_cd584725c183 -->|calls| 041ca752_10c1_3cda_1f5c_02f44a01310e
  style 229919e6_9735_4317_1205_cd584725c183 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

compiler/packages/babel-plugin-react-compiler/src/HIR/Dominator.ts lines 87–94

  get(id: T): T | null {
    const dominator = this.#nodes.get(id);
    CompilerError.invariant(dominator !== undefined, {
      reason: 'Unknown node',
      loc: GeneratedSource,
    });
    return dominator === id ? null : dominator;
  }

Subdomains

Frequently Asked Questions

What does get() do?
get() is a function in the react codebase, defined in compiler/packages/babel-plugin-react-compiler/src/HIR/Dominator.ts.
Where is get() defined?
get() is defined in compiler/packages/babel-plugin-react-compiler/src/HIR/Dominator.ts at line 87.
What does get() call?
get() calls 2 function(s): get, invariant.
What calls get()?
get() is called by 2 function(s): createControlDominators, get.

Analyze Your Own Codebase

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

Try Supermodel Free