You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If I do something like so, it displays the key as the default value for this translation. $_("Hi!") > Hi!
However, if I do $_("Hi, {name}", { values: { name: "Bryan" } }), it does not use the key as the default value. Instead, I get the value back of Hi, {name} where I'm expecting Hi, Bryan.
To Reproduce
It's very simple, try to display a translated string with values that is not in your default language json.
Expected behavior
In my opinion, the expected behavior is that you would treat the key as the default value even if it has variables. This is how most i18n libraries work and it's also how svelte-i18n works without values.
The text was updated successfully, but these errors were encountered:
Describe the bug
If I do something like so, it displays the key as the default value for this translation.
$_("Hi!")
>Hi!
However, if I do
$_("Hi, {name}", { values: { name: "Bryan" } })
, it does not use the key as the default value. Instead, I get the value back ofHi, {name}
where I'm expectingHi, Bryan
.To Reproduce
It's very simple, try to display a translated string with values that is not in your default language json.
Expected behavior
In my opinion, the expected behavior is that you would treat the key as the default value even if it has variables. This is how most i18n libraries work and it's also how svelte-i18n works without values.
The text was updated successfully, but these errors were encountered: