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

Commit 428f2b5

Browse files
committed
feat(ngInclude): allow ngInclude on css class
And make it terminal so that it does not compile its content, which would cause leaks.
1 parent 199ac26 commit 428f2b5

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/ng/directive/ngInclude.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
/**
44
* @ngdoc directive
55
* @name angular.module.ng.$compileProvider.directive.ng-include
6-
* @restrict EA
6+
* @restrict ECA
77
*
88
* @description
99
* Fetches, compiles and includes an external HTML fragment.
@@ -74,7 +74,8 @@
7474
var ngIncludeDirective = ['$http', '$templateCache', '$anchorScroll', '$compile',
7575
function($http, $templateCache, $anchorScroll, $compile) {
7676
return {
77-
restrict: 'EA',
77+
restrict: 'ECA',
78+
terminal: true,
7879
compile: function(element, attr) {
7980
var srcExp = attr.ngInclude || attr.src,
8081
onloadExp = attr.onload || '',

0 commit comments

Comments
 (0)