Lesser known AngularJS features

function bootstrap() {  
  angular.element(document).ready(function() {
    var injector = angular.bootstrap(document, ['App']);

    // Manually invoke a Service method
    injector.invoke(function(InjectedService) {
        InjectedService.invokeAnotherMethod();
    });
  });

}

// Angular Manual Bootstrap
function ngBootstrap() {

  // Prefetch services
  var injector = angular.injector(["ng", "App"]);
  var $q = injector.get("$q");

  var injectedService = injector.get("InjectedService");

  var invokedPromise = injectedService.invokeMethod();

  $q.all([invokedPromise]).then(bootstrap);

}