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
{{ message }}
This repository has been archived by the owner on Oct 4, 2019. It is now read-only.
When using the wc-api to get general settings /wc/v2/settings/general, the woocommerce_currency object has an options array that has the following format:
{AED: "United Arab Emirates dirham (د.إ)"}
This results in having to use a regex to separate the country and currency name from the currency symbol.
I propose that the options object should take this format:
{ AED: { country: "United Arab Emirates", currency: "dirham", symbol: "د.إ" } }
It may be good to look into a data endpoint instead/in addition, since this is a setting, not a way to get the correct symbol.
When showing a dropdown in settings a user may not want to show the full country plus the symbol. Calling a second endpoint to get just the symbols seems needless. Breaking out the data into fields makes the API more flexible.
It may be good to look into a data endpoint instead/in addition, since this is a setting, not a way to get the correct symbol.
From woocommerce/woocommerce#15101
The text was updated successfully, but these errors were encountered: