MCPcopy
hub / github.com/angular-ui/ui-router / invokeFirstDriver

Function invokeFirstDriver

test/angular/1.4/angular-animate.js:3175–3188  ·  view source on GitHub ↗
(animationDetails)

Source from the content-addressed store, hash-verified

3173 }
3174
3175 function invokeFirstDriver(animationDetails) {
3176 // we loop in reverse order since the more general drivers (like CSS and JS)
3177 // may attempt more elements, but custom drivers are more particular
3178 for (var i = drivers.length - 1; i >= 0; i--) {
3179 var driverName = drivers[i];
3180 if (!$injector.has(driverName)) continue; // TODO(matsko): remove this check
3181
3182 var factory = $injector.get(driverName);
3183 var driver = factory(animationDetails);
3184 if (driver) {
3185 return driver;
3186 }
3187 }
3188 }
3189
3190 function beforeStart() {
3191 element.addClass(NG_ANIMATE_CLASSNAME);

Callers 1

angular-animate.jsFile · 0.70

Calls 1

factoryFunction · 0.70

Tested by

no test coverage detected