I've a scenario which I want to run a custom directive on the DOM that ng-bind-html
create.
Basicly I've to customize the behavior of the html tag <a>
because the html that is loading is unsafe and when the user click the link I've to execute some functions before anything happens, aka, the click
event of jqLite.
So my original ideia was create a directive that modifies the behavior of any <a>
inside the container that I put the attribute of my directive.
This works fine, until I combine with ng-bind-html
, my directive runs before the ng-bind-html
compile the string into html and attached to the DOM.
So, is any way to run my custom directive after the ng-bind-html
run?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…