DoIt
DoIt

Reputation: 3438

evaluation an angular expression within quotes in html

I came across a scenario where I had to evaluate an angular expression within quotes like below

<a href="mailto:{{account["email"]}}"

But the above doesn't properly evaluate content in child quotes(repEmail). How do I resolve this?

Upvotes: 1

Views: 141

Answers (1)

stefan bachert
stefan bachert

Reputation: 9616

try

 <a href="mailto:{{account['email']}}"

or

 <a href="mailto:{{account.email}}"

or

 <a ng-attr-href="mailto:{{account['email']}}"

or

 <a ng-attr-href="mailto:{{account.email}}"

Upvotes: 2

Related Questions