angular-recursion
angular-recursion copied to clipboard
Extra dom elements created
Here is the example: http://jsfiddle.net/HB7LU/7721/
And screenshot:
The template within the recursive directive (gt-view) looks like this:
template: [
'<div class="contents">',
'<div class="gt-view-content">',
'<h1>{{view.title}}</h1>',
'</div>',
'<div class="gt-view-child-container" ng-if="view.childView">',
'<gt-view view="view.childView"></gt-view>',
'</div>',
'</div>',
].join('')
So regardless if childView is populated in the model, I am getting another gt-view rendered Ideas?
Your fiddle uses angular 1.0.1. It works better with a more up to date angular version, like 1.4.8..