How do I translate something with quotation marks?

1

When trying to do the translation, I do not get the quotes to write in the mdInput placeholder=". Can I put it bareback, or do I need a variable (how would I put it)?

<input #pin type="password" mdInput placeholder="{{Password | translate}}" formControlName="pin">

The result

"Password": "Password555555",
    
asked by Enric 14.03.2018 в 12:34
source

1 answer

1

I assume you're using ngx-translate :

When you use

{{ Password | translate }}

Angular assumes that Password is an attribute of the component. If you want to use "Password" as the key to look for in your Internationalization JSON file (i18n), you have to put it as a literal:

{{ 'Password' | translate }}
    
answered by 14.03.2018 / 12:42
source