I wanted to find out the difference between the .config and .run functions in AngularJS. I was using my .config for setting up routes, but
.config
.run
The .config block is executed during the provider registration and configuration phase. It' a module level block.
The.run block is executed after the config block. It's used to inject services and constants.