I would like to conditionally apply a title attribute to an element, which I am attempting like so:
<div class="option-title" [attr.title]="isTitleTruncated() ? option.title : null">
{{option.title}}
</div>
But I would like to pass in the element reference to my function being used on the condition, but have been unable to do so. I tried using this and that gives me the component instance, but I want the actual div itself. Is this possible?