vue-storefront icon indicating copy to clipboard operation
vue-storefront copied to clipboard

[Feature]: Improve i18n-cookies

Open sequensucks opened this issue 3 years ago • 0 comments
trafficstars

How the project can be improved?

It will be great. If you can update a getCurrencyByLocale method in the https://github.com/vuestorefront/vue-storefront/blob/main/packages/core/nuxt-module/lib/plugins/i18n-cookies.js

Like this

const getCurrencyByLocale = (locale) => i18n.numberFormats?.[locale]?.currency?.currency || i18n.numberFormats?.[i18n.fallbackLocale?.[locale][0]]?.currency?.currency || i18nOptions.currency || (i18nOptions.currencies.length && i18nOptions.currencies[0].name);

Because i have not standard locales and i get numberFormats across a fallbackLocale prop.

What are the acceptance criteria?

  • [ ]

Additional information

No response

What version of Vue Storefront this feature can be implemented?

2.5.2

Code of Conduct

  • [X] I agree to follow this project's Code of Conduct

sequensucks avatar Dec 15 '21 15:12 sequensucks