Home / Function/ makeBlockId() — react Function Reference

makeBlockId() — react Function Reference

Architecture documentation for the makeBlockId() function in HIR.ts from the react codebase.

Entity Profile

Dependency Diagram

graph TD
  11080cce_bbf7_2d34_25af_532ed4173235["makeBlockId()"]
  18a78965_f593_105b_e5e8_07001321c2ec["HIR.ts"]
  11080cce_bbf7_2d34_25af_532ed4173235 -->|defined in| 18a78965_f593_105b_e5e8_07001321c2ec
  b5270442_a3d4_c0ac_4004_38c1f96753df["nextBlockId()"]
  b5270442_a3d4_c0ac_4004_38c1f96753df -->|calls| 11080cce_bbf7_2d34_25af_532ed4173235
  120d83a3_3b47_09ef_b55b_3acb35934a1f["constructor()"]
  120d83a3_3b47_09ef_b55b_3acb35934a1f -->|calls| 11080cce_bbf7_2d34_25af_532ed4173235
  2a23449a_1dec_0ba3_8f5a_0e9e83d42add["reserve()"]
  2a23449a_1dec_0ba3_8f5a_0e9e83d42add -->|calls| 11080cce_bbf7_2d34_25af_532ed4173235
  c201bbda_dc3c_7b58_7ce0_7d61d25ef972["emitOutlinedFn()"]
  c201bbda_dc3c_7b58_7ce0_7d61d25ef972 -->|calls| 11080cce_bbf7_2d34_25af_532ed4173235
  041ca752_10c1_3cda_1f5c_02f44a01310e["invariant()"]
  11080cce_bbf7_2d34_25af_532ed4173235 -->|calls| 041ca752_10c1_3cda_1f5c_02f44a01310e
  style 11080cce_bbf7_2d34_25af_532ed4173235 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

compiler/packages/babel-plugin-react-compiler/src/HIR/HIR.ts lines 1715–1721

export function makeBlockId(id: number): BlockId {
  CompilerError.invariant(id >= 0 && Number.isInteger(id), {
    reason: 'Expected block id to be a non-negative integer',
    loc: GeneratedSource,
  });
  return id as BlockId;
}

Subdomains

Calls

Frequently Asked Questions

What does makeBlockId() do?
makeBlockId() is a function in the react codebase, defined in compiler/packages/babel-plugin-react-compiler/src/HIR/HIR.ts.
Where is makeBlockId() defined?
makeBlockId() is defined in compiler/packages/babel-plugin-react-compiler/src/HIR/HIR.ts at line 1715.
What does makeBlockId() call?
makeBlockId() calls 1 function(s): invariant.
What calls makeBlockId()?
makeBlockId() is called by 4 function(s): constructor, emitOutlinedFn, nextBlockId, reserve.

Analyze Your Own Codebase

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

Try Supermodel Free