Open mazswojejzony opened 8 years ago
Any updates? :-)
Hi,
I just published a 0.1.1 version.
The notation for your example would be:
<span i18n='{"translation_key": {"postProcess": "interval", "count": {{someComponentVariable}}}}'></span>
There is still log of debug messages in the console if you need to see what happens.
Is that working for you?
I tried to use the feature and passing options works well. However, I observed two problems:
{{someComponentVariable}}
changes, change is not reflected to directive).Hi, Sure, feel free to submit a PR with your solution. Thanks!
Hi, I've seen change back to observable in the code - have you observed any problems with Promise implementation?
Yes, the modification introduced a problem with the i18n-directives that are started before the i18n module is initialized. With your modifications, these directives wasn't updated after the i18n module is initialized.
That's true, but why is that a problem? Isn't the point of using Observable with subscribe exactly the same, to delay getting the translation until initialization is done? I hope you don't mind the questions, probably I didn't catch some part of the idea - just trying to understand.
This is required to properly handle plural forms, context, etc. For example see: http://i18next.com/translate/pluralInterval/
It would be great to be able to use i18nDirective like this: