I have a directive which is triggered to hide an element when a condition is reached.
var hideElement = function(){
el = element.find('.myelement');
$(el).addClass('hideme');
};
then in a conditional I trigger the hideElement function
if(j >= count){
hideElement ();
}
how do I refactor this on the partial to make a change to the ng-class?
<div
data-directivename
data-increment="increment"
data-count="count"
ng-class="{'timetohide': hide}"
>
<div class="myelement"></div>
</div>