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

Function match

code/redux/public/app.js:19025–19034  ·  view source on GitHub ↗
(arg, factories, name)

Source from the content-addressed store, hash-verified

19023 */
19024
19025function match(arg, factories, name) {
19026 for (var i = factories.length - 1; i >= 0; i--) {
19027 var result = factories[i](arg);
19028 if (result) return result;
19029 }
19030
19031 return function (dispatch, options) {
19032 throw new Error('Invalid value of type ' + typeof arg + ' for ' + name + ' argument when connecting component ' + options.wrappedComponentName + '.');
19033 };
19034}
19035
19036function strictEqual(a, b) {
19037 return a === b;

Callers 1

createConnectFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected