I am using action sheet and transloco translate plugin in my ionic 5 angular app.
When I use transloco on text the APP is considering as string.
buttons: [{
text: "{{'channel.edit' | transloco}}",
icon: 'create-outline',
So what should be the correct way to pass the translated text?
Use TranslateService to translate any variables alertTitle;
constructor(translate: TranslateService) {
translateService.get('channel.edit').subscribe(
value => {
this.alertTitle = value;
}
)
then
buttons: [{
text: this.alertTitle,
icon: 'create-outline',