AngularJs 1.5 component throws error if using nested directives with templateUrl #15815
Description
Do you want to request a feature or report a bug?
Bug
What is the current behavior?
Having a recursive AngularJs 1.5 component with templateUrl throws
[$rootScope:infdig] 10 $digest() iterations reached. Aborting!
While having the template inline works fine. See plnkr for this behavior.
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem via https://plnkr.co or similar (template: http://plnkr.co/edit/tpl:yBpEi4).
http://plnkr.co/edit/gCP6H9EIWa1pEJ0ywp0r?p=preview
Using inline template works fine while templateUrl throws error.
What is the expected behavior?
Having a templateUrl should work just as well as having template in a recursive component. Changing the plnkr to have the template inline instead, no error is thrown.
What is the motivation / use case for changing the behavior?
It’s inconsistent behavior and doesn’t seem to work for templateUrl.
Which versions of AngularJS, and which browser / OS are affected by this issue? Did this work in previous versions of AngularJS? Please also test with the latest stable and snapshot (https://code.angularjs.org/snapshot/) versions.
Angular 1.5.11 and later (all browsers).
Other information (e.g. stacktraces, related issues, suggestions how to fix)