Article
home/blog/Loading

The difference between services and providers in AngularJS

An easy way to remember it is that Providers are at config time (before the application has finished loading).

Services are while the application is running.

Example Service and Provider init

angular.module('moduleName', [])
       .config((injectables) => { // provider & constants
           // do configuration
       })
       .run((injectables) => { // services & constants
           // do initialization
       });