I see many people using self invoking functions as a wrapper for angular modules e.g.
(function() {
  var app = angular.module('directivesModule');
  app.directive('domDirective', function () {
      return {
          restrict: 'A',
          link: function ($scope, element, attrs) {
          }
      };
  });
}());
Is there any advantage of wrapping like this? Or it is just a matter of coding style?
Thank you!
