convertMemberExpressionToJsx() — react Function Reference
Architecture documentation for the convertMemberExpressionToJsx() function in CodegenReactiveFunction.ts from the react codebase.
Entity Profile
Dependency Diagram
graph TD 4ea7ed84_801a_b55e_a362_a643004c9020["convertMemberExpressionToJsx()"] d625ad1a_bef9_abdc_5a5b_206000a43505["CodegenReactiveFunction.ts"] 4ea7ed84_801a_b55e_a362_a643004c9020 -->|defined in| d625ad1a_bef9_abdc_5a5b_206000a43505 6a814fad_ae8c_e7c7_c63e_c26c048be543["codegenInstructionValue()"] 6a814fad_ae8c_e7c7_c63e_c26c048be543 -->|calls| 4ea7ed84_801a_b55e_a362_a643004c9020 54d623b1_ac7c_dd74_8b03_de9e93a36587["invariant()"] 4ea7ed84_801a_b55e_a362_a643004c9020 -->|calls| 54d623b1_ac7c_dd74_8b03_de9e93a36587 style 4ea7ed84_801a_b55e_a362_a643004c9020 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
compiler/packages/babel-plugin-react-compiler/src/ReactiveScopes/CodegenReactiveFunction.ts lines 2455–2474
function convertMemberExpressionToJsx(
expr: t.MemberExpression,
): t.JSXMemberExpression {
CompilerError.invariant(expr.property.type === 'Identifier', {
reason: 'Expected JSX member expression property to be a string',
loc: expr.loc ?? GeneratedSource,
});
const property = t.jsxIdentifier(expr.property.name);
if (expr.object.type === 'Identifier') {
return t.jsxMemberExpression(t.jsxIdentifier(expr.object.name), property);
} else {
CompilerError.invariant(expr.object.type === 'MemberExpression', {
reason:
'Expected JSX member expression to be an identifier or nested member expression',
loc: expr.object.loc ?? GeneratedSource,
});
const object = convertMemberExpressionToJsx(expr.object);
return t.jsxMemberExpression(object, property);
}
}
Domain
Subdomains
Defined In
Calls
Called By
Source
Frequently Asked Questions
What does convertMemberExpressionToJsx() do?
convertMemberExpressionToJsx() is a function in the react codebase, defined in compiler/packages/babel-plugin-react-compiler/src/ReactiveScopes/CodegenReactiveFunction.ts.
Where is convertMemberExpressionToJsx() defined?
convertMemberExpressionToJsx() is defined in compiler/packages/babel-plugin-react-compiler/src/ReactiveScopes/CodegenReactiveFunction.ts at line 2455.
What does convertMemberExpressionToJsx() call?
convertMemberExpressionToJsx() calls 1 function(s): invariant.
What calls convertMemberExpressionToJsx()?
convertMemberExpressionToJsx() is called by 1 function(s): codegenInstructionValue.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free