Open longdoan7421 opened 2 years ago
thanks @longdoan7421 for submitting this PR. Did you plan to also complete any other methods?
Hi @mashpie, I'm gonna continue working on the plural method __n
later today. My plan was that I will change the method getLocaleFromObject
to return the defaultLocale
instead of undefined
as default value. Then, use that method to get locale config from the input in method __n
. Do you think whether it would affect anything?
For the other methods, I don't see they have option to pass locale
like i18n.__
and i18n.__n
(not sure if I am right, maybe you can correct me for this part).
Hi @mashpie, sorry for the delay. I added the fix for API i18n.__n
. Please take a look if there is something need to be improved.
Thanks @longdoan7421 - and sry for delay. LGTM!
Hope to review closer and of week.
Any updates on this?
@longdoan7421 can you fix __mf
as well?
@EinfachHans I was not aware of __mf
function. Could you point me the documentation for that function? I will look at it and see what I can do.
I use it because it integrates with messageformat: https://github.com/mashpie/i18n-node#i18n__mf At the end of the day this patch should be applied to all functions i guess 🤔
Hi @mashpie, I added a similar fix for method i18n.__mf
. When you have time could you check this PR? Thank you.
Close #501.
i18n.__
i18n.__n