Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit 3dafcba

Browse files
committed
feat(ngTransclude): allow ngTransclude to be used as an element
Closes #8141
1 parent 071cbdb commit 3dafcba

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/ng/directive/ngTransclude.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
/**
44
* @ngdoc directive
55
* @name ngTransclude
6-
* @restrict AC
6+
* @restrict EAC
77
*
88
* @description
99
* Directive that marks the insertion point for the transcluded DOM of the nearest parent directive that uses transclusion.
@@ -24,7 +24,7 @@
2424
scope: { title:'@' },
2525
template: '<div style="border: 1px solid black;">' +
2626
'<div style="background-color: gray">{{title}}</div>' +
27-
'<div ng-transclude></div>' +
27+
'<ng-transclude></ng-transclude>' +
2828
'</div>'
2929
};
3030
})
@@ -55,6 +55,7 @@
5555
*
5656
*/
5757
var ngTranscludeDirective = ngDirective({
58+
restrict: 'EAC',
5859
link: function($scope, $element, $attrs, controller, $transclude) {
5960
if (!$transclude) {
6061
throw minErr('ngTransclude')('orphan',

0 commit comments

Comments
 (0)