LegacyClsConsumer Class — react Architecture
Architecture documentation for the LegacyClsConsumer class in ReactDOMServerIntegrationLegacyContextDisabled-test.internal.js from the react codebase.
Entity Profile
Dependency Diagram
graph TD 167c2077_4589_41ef_4350_0149bca79549["LegacyClsConsumer"] f86e0bfe_918b_05b9_e878_e3df8ce0d8fa["ReactDOMServerIntegrationLegacyContextDisabled-test.internal.js"] 167c2077_4589_41ef_4350_0149bca79549 -->|defined in| f86e0bfe_918b_05b9_e878_e3df8ce0d8fa 2bb5d14e_71f8_e582_77ff_57f19542647f["shouldComponentUpdate()"] 167c2077_4589_41ef_4350_0149bca79549 -->|method| 2bb5d14e_71f8_e582_77ff_57f19542647f 0a90a371_5853_d2ac_b9f3_5b59ecd4235a["UNSAFE_componentWillReceiveProps()"] 167c2077_4589_41ef_4350_0149bca79549 -->|method| 0a90a371_5853_d2ac_b9f3_5b59ecd4235a 17ab4ab5_b9d9_5022_ba65_7705ca076978["UNSAFE_componentWillUpdate()"] 167c2077_4589_41ef_4350_0149bca79549 -->|method| 17ab4ab5_b9d9_5022_ba65_7705ca076978 61772f85_492c_2863_b5f0_2d6371a67398["render()"] 167c2077_4589_41ef_4350_0149bca79549 -->|method| 61772f85_492c_2863_b5f0_2d6371a67398
Relationship Graph
Source Code
packages/react-dom/src/__tests__/ReactDOMServerIntegrationLegacyContextDisabled-test.internal.js lines 71–88
class LegacyClsConsumer extends React.Component {
static contextTypes = {
foo() {},
};
shouldComponentUpdate(nextProps, nextState, nextContext) {
lifecycleContextLog.push(nextContext);
return true;
}
UNSAFE_componentWillReceiveProps(nextProps, nextContext) {
lifecycleContextLog.push(nextContext);
}
UNSAFE_componentWillUpdate(nextProps, nextState, nextContext) {
lifecycleContextLog.push(nextContext);
}
render() {
return formatValue(this.context);
}
}
Defined In
Source
Frequently Asked Questions
What is the LegacyClsConsumer class?
LegacyClsConsumer is a class in the react codebase, defined in packages/react-dom/src/__tests__/ReactDOMServerIntegrationLegacyContextDisabled-test.internal.js.
Where is LegacyClsConsumer defined?
LegacyClsConsumer is defined in packages/react-dom/src/__tests__/ReactDOMServerIntegrationLegacyContextDisabled-test.internal.js at line 71.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free