N
Novu•14mo ago
Kai Pradel

HTML being rendered as text in email message

I am using the #each iterator to loop through an array. When using the following code, the A HREF html portion get renderesd as text in the email, not as HTML. How would I need to change the following template snipped: {{#each domains}} <a href="https://dailydomains.io/app?domain={{domain}}">{{domain}}</a><br/> {{/each}} Thanks in advance. Kai
No description
7 Replies
Kai Pradel
Kai Pradel•14mo ago
No description
Pawan Jain
Pawan Jain•14mo ago
Hi @.mrjoojoo Please try this above code in custom code tab Remove {{{ }}} around <a> tag
No description
Kai Pradel
Kai Pradel•14mo ago
Pawan, same issue. I resorted to creating the a href payload server side and pass it in as an array of obejcts with the fully formed a href string. Not ideal but I get the n+1 issue here. Would be awesome to do that all in the template.
Pawan Jain
Pawan Jain•14mo ago
Hi Kai Could you share more information on how the above approach is failing? maybe with example payload?
Zac Clifton
Zac Clifton•12mo ago
@Pawan Jain I am having the same issue here too
Zac Clifton
Zac Clifton•12mo ago
No description
Pawan Jain
Pawan Jain•11mo ago
@Zac Clifton
1. sending link value from payload <a href={{link}}> Click on this link </a> 2. or using hard coded href value <a href="https://docs.novu.co/getting-started/commercial-open-source"> Click on this link </a> Both options are working for me 😅 We are closing this post due to inactivity. Feel free to create a new post if you have any questions or you are still facing issue
Want results from more Discord servers?
Add your server