Angular — Directives: using a dynamic template
Gerard Sans
85

This method of using ng-include worked great in resolving my bind variables. However in my directive I update the DOM in the link() function using:

var regions = element[0].querySelectorAll(‘g’);

to get the elements I need to process. This now doesn’t work, I think because I can’t access the included source code. How can I now access the html that I have included dynamically ?

Show your support

Clapping shows how much you appreciated AllenJC’s story.