validateEventDispatches() — react Function Reference
Architecture documentation for the validateEventDispatches() function in EventPluginUtils.js from the react codebase.
Entity Profile
Dependency Diagram
graph TD 92e5bd6b_559e_70c8_cde0_8c69f4e5a6ec["validateEventDispatches()"] c47175ea_4123_c4e5_c30d_de7506f00f3a["EventPluginUtils.js"] 92e5bd6b_559e_70c8_cde0_8c69f4e5a6ec -->|defined in| c47175ea_4123_c4e5_c30d_de7506f00f3a 220a1380_3b15_b89d_5bbb_e6ffc9e2727a["executeDispatchesInOrder()"] 220a1380_3b15_b89d_5bbb_e6ffc9e2727a -->|calls| 92e5bd6b_559e_70c8_cde0_8c69f4e5a6ec 2d95f6f2_0848_5f11_99ba_1c6e181a70c9["executeDispatchesInOrderStopAtTrueImpl()"] 2d95f6f2_0848_5f11_99ba_1c6e181a70c9 -->|calls| 92e5bd6b_559e_70c8_cde0_8c69f4e5a6ec 87ca11ba_f1b0_34e6_deb2_620dc868ac55["executeDirectDispatch()"] 87ca11ba_f1b0_34e6_deb2_620dc868ac55 -->|calls| 92e5bd6b_559e_70c8_cde0_8c69f4e5a6ec style 92e5bd6b_559e_70c8_cde0_8c69f4e5a6ec fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/react-native-renderer/src/legacy-events/EventPluginUtils.js lines 37–60
function validateEventDispatches(event) {
if (__DEV__) {
const dispatchListeners = event._dispatchListeners;
const dispatchInstances = event._dispatchInstances;
const listenersIsArr = isArray(dispatchListeners);
const listenersLen = listenersIsArr
? dispatchListeners.length
: dispatchListeners
? 1
: 0;
const instancesIsArr = isArray(dispatchInstances);
const instancesLen = instancesIsArr
? dispatchInstances.length
: dispatchInstances
? 1
: 0;
if (instancesIsArr !== listenersIsArr || instancesLen !== listenersLen) {
console.error('EventPluginUtils: Invalid `event`.');
}
}
}
Domain
Subdomains
Source
Frequently Asked Questions
What does validateEventDispatches() do?
validateEventDispatches() is a function in the react codebase, defined in packages/react-native-renderer/src/legacy-events/EventPluginUtils.js.
Where is validateEventDispatches() defined?
validateEventDispatches() is defined in packages/react-native-renderer/src/legacy-events/EventPluginUtils.js at line 37.
What calls validateEventDispatches()?
validateEventDispatches() is called by 3 function(s): executeDirectDispatch, executeDispatchesInOrder, executeDispatchesInOrderStopAtTrueImpl.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free