Home / Function/ isReactAPI() — react Function Reference

isReactAPI() — react Function Reference

Architecture documentation for the isReactAPI() function in Program.ts from the react codebase.

Entity Profile

Dependency Diagram

graph TD
  c475eaae_58c2_0cdb_d73f_64cab87dbc41["isReactAPI()"]
  9aa4477d_960b_1ea1_b6d9_36076aaa70bd["Program.ts"]
  c475eaae_58c2_0cdb_d73f_64cab87dbc41 -->|defined in| 9aa4477d_960b_1ea1_b6d9_36076aaa70bd
  8e26b3bb_a1d7_155c_c8b6_2082b5792efb["isForwardRefCallback()"]
  8e26b3bb_a1d7_155c_c8b6_2082b5792efb -->|calls| c475eaae_58c2_0cdb_d73f_64cab87dbc41
  ee42cd13_5e0a_8266_50bb_9daa20e7a0b2["isMemoCallback()"]
  ee42cd13_5e0a_8266_50bb_9daa20e7a0b2 -->|calls| c475eaae_58c2_0cdb_d73f_64cab87dbc41
  style c475eaae_58c2_0cdb_d73f_64cab87dbc41 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

compiler/packages/babel-plugin-react-compiler/src/Entrypoint/Program.ts lines 1065–1078

function isReactAPI(
  path: NodePath<t.Expression | t.PrivateName | t.V8IntrinsicIdentifier>,
  functionName: string,
): boolean {
  const node = path.node;
  return (
    (node.type === 'Identifier' && node.name === functionName) ||
    (node.type === 'MemberExpression' &&
      node.object.type === 'Identifier' &&
      node.object.name === 'React' &&
      node.property.type === 'Identifier' &&
      node.property.name === functionName)
  );
}

Domain

Subdomains

Frequently Asked Questions

What does isReactAPI() do?
isReactAPI() is a function in the react codebase, defined in compiler/packages/babel-plugin-react-compiler/src/Entrypoint/Program.ts.
Where is isReactAPI() defined?
isReactAPI() is defined in compiler/packages/babel-plugin-react-compiler/src/Entrypoint/Program.ts at line 1065.
What calls isReactAPI()?
isReactAPI() is called by 2 function(s): isForwardRefCallback, isMemoCallback.

Analyze Your Own Codebase

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

Try Supermodel Free