0

Is it possible to prepend/append some hardcoded text inside a placeholder? e.g we have some text like "Example: " and we want this to appear before translated text in the placeholder.

Original html without prepended/appended static text:

<input type="text" data-i18n="[placeholder]translationKEY"/>

Related question: Translate custom attributes with i18next (placeholder, value)

1 Answers1

0

Only option i see is custom code or using the nesting feature https://www.i18next.com/nesting.html and nest "Example: " into the value of the "translationKEY"'s value

jamuhl
  • 4,352
  • 2
  • 25
  • 31
  • Forgot to mention that ideally I should not change any of the namespace translations etc. I guess custom code means e.g using js/ jQuery to find all these placeholders and add the prefix on attribute? – spyDeveloper Nov 03 '17 at 12:40