Internationalization (i18n)enhancementhelp wanted
Description
Per discussion in https://github.com/reactioncommerce/reaction/issues/6517, it would be good to work toward being able to do currency formatting differently depending on desired language.
Rough idea:
- Reaction
formatMoney, passes through to accounting-js. It does not support language-specificformatso we would need to resolve the correctformatvalue before callingaccounting.formatMoney. This means ReactionformatMoneywould need to accept a new optional argumentlanguage, or maybe just make an entirely new function. - Need to invent some additional property in
CurrencyDefinitionsthat has format keyed by language code - (create an issue for this in
api-core) Most formatting is done automatically in the Reaction API, based on theMoneytype in GraphQL resolvers. But this isn't currently aware of what language the client wants. Probably every field that hasMoneytype would need to be updated to accept an optionallanguageparam, andMoneyresolver would need to pass that along toformatMoney.