I can't provide much example code. I'm unable to paste the code I'm working with for reasons of confidentiality, and I'm too new to Angular to be able to produce a minimum working example.
I have a button with a click element and an i18n element:
<button type="button"
(click)="myFunction('temporaryValue')"
i18n="@@nonEnglishText">
English Text
</button>
What I aim to do is replace temporaryValue in the click element with the value of i18n, but I don't know how to achieve this. I tried the following method, but it sends the string itself instead of the value it's supposed to refer to:
(click)="myFunction('@@nonEnglishText')"
I also tried the following method, but it doesn't work:
i18n-(click)="myFunction('@@nonEnglishText')"
How do I achieve sending the correct value to the function?
You can't ,you have to translate the temporaryValue somewhere else , where do you store-it or how do you get the value ?