cfg-switch-exhaustive.js — react Source File
Architecture documentation for cfg-switch-exhaustive.js, a javascript file in the react codebase. 1 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR 94a5e6ef_a9a3_3976_d5c1_4fe899d1d7a7["cfg-switch-exhaustive.js"] 006eec3d_77a9_4a47_e6c1_a96d7a6c9c05["shared-runtime"] 94a5e6ef_a9a3_3976_d5c1_4fe899d1d7a7 --> 006eec3d_77a9_4a47_e6c1_a96d7a6c9c05 style 94a5e6ef_a9a3_3976_d5c1_4fe899d1d7a7 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
// props.a.b should be added as a unconditional dependency to the reactive
// scope that produces x, since it is accessed unconditionally in all cfg
// paths
import {identity} from 'shared-runtime';
function useCondDepInSwitch(props, other) {
const x = {};
switch (identity(other)) {
case 1:
x.a = props.a.b;
break;
case 2:
x.b = props.a.b;
break;
default:
x.c = props.a.b;
}
return x;
}
export const FIXTURE_ENTRYPOINT = {
fn: useCondDepInSwitch,
params: [{a: {b: 2}}, 2],
};
Domain
Subdomains
Functions
Dependencies
- shared-runtime
Source
Frequently Asked Questions
What does cfg-switch-exhaustive.js do?
cfg-switch-exhaustive.js is a source file in the react codebase, written in javascript. It belongs to the TestingUtilities domain, Fixtures subdomain.
What functions are defined in cfg-switch-exhaustive.js?
cfg-switch-exhaustive.js defines 1 function(s): useCondDepInSwitch.
What does cfg-switch-exhaustive.js depend on?
cfg-switch-exhaustive.js imports 1 module(s): shared-runtime.
Where is cfg-switch-exhaustive.js in the architecture?
cfg-switch-exhaustive.js is located at compiler/packages/babel-plugin-react-compiler/src/__tests__/fixtures/compiler/reduce-reactive-deps/cfg-switch-exhaustive.js (domain: TestingUtilities, subdomain: Fixtures, directory: compiler/packages/babel-plugin-react-compiler/src/__tests__/fixtures/compiler/reduce-reactive-deps).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free