In my project I have a couple of providers which I initialise during startup
angular.module('myApp', [])
    .config((barFooProvider, ....) => {
        barFooProvider.setAPIPath = '/a/b/c';
        ...
    });
As you can see I define an api-path here which is a string. But how can I set for example a factory ? Or is the only way to define the name of the service and later on use the $injector ?
 
     
     
     
    