MCPcopy Create free account
hub / github.com/krasimir/react-in-patterns / accumulateDispatches

Function accumulateDispatches

code/dependency-injection/public/app.js:2803–2812  ·  view source on GitHub ↗

* Accumulates without regard to direction, does not look for phased * registration names. Same as `accumulateDirectDispatchesSingle` but without * requiring that the `dispatchMarker` be the same as the dispatched ID.

(inst, ignoredDirection, event)

Source from the content-addressed store, hash-verified

2801 * requiring that the `dispatchMarker` be the same as the dispatched ID.
2802 */
2803function accumulateDispatches(inst, ignoredDirection, event) {
2804 if (inst && event && event.dispatchConfig.registrationName) {
2805 var registrationName = event.dispatchConfig.registrationName;
2806 var listener = getListener(inst, registrationName);
2807 if (listener) {
2808 event._dispatchListeners = accumulateInto(event._dispatchListeners, listener);
2809 event._dispatchInstances = accumulateInto(event._dispatchInstances, inst);
2810 }
2811 }
2812}
2813
2814/**
2815 * Accumulates dispatches on an `SyntheticEvent`, but only for the

Callers 1

Calls 2

getListenerFunction · 0.70
accumulateIntoFunction · 0.70

Tested by

no test coverage detected