MCPcopy Create free account
hub / github.com/EricSimons/ionic-course / reverseParams

Function reverseParams

code/songhop/www/lib/angular/angular.js:356–358  ·  view source on GitHub ↗

* when using forEach the params are value, key, but it is often useful to have key, value. * @param {function(string, *)} iteratorFn * @returns {function(*, string)}

(iteratorFn)

Source from the content-addressed store, hash-verified

354 * @returns {function(*, string)}
355 */
356function reverseParams(iteratorFn) {
357 return function(value, key) { iteratorFn(key, value); };
358}
359
360/**
361 * A consistent way of creating unique IDs in angular.

Callers 2

supportObjectFunction · 0.70
$CompileProviderFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected