Skip to content

Instantly share code, notes, and snippets.

@timkindberg
Last active October 22, 2015 18:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save timkindberg/2c9ae631ee1a7428e421 to your computer and use it in GitHub Desktop.
Save timkindberg/2c9ae631ee1a7428e421 to your computer and use it in GitHub Desktop.
ng-forward ng1 migration (before)
angular.module('app', []);
(function() {
angular.module('app')
.directive('componentA', function() {
return ['serviceA', function linkFn(serviceA){}]
});
})()
(function() {
angular.module('app')
.directive('componentB', function() {
return ['serviceB', function linkFn(serviceA){}]
});
})()
(function() {
angular.module('app')
.service('serviceA', function() {});
})()
(function() {
angular.module('app')
.service('serviceB', function() {});
})()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment