Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- app.directive('directive', function($compile) {
- return {
- link: function (scope, element, attrs) {
- element.attr('another-directive', '');
- if (element.data('compileRecursion')) {
- element.data('compileRecursion', false);
- } else {
- element.data('compileRecursion', true);
- $compile(element)(scope);
- }
- }
- };
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement