Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use locale value for automatically obtaining a default currency in fmt_currency() #1347

Merged
merged 24 commits into from Jun 11, 2023

Conversation

rich-iannone
Copy link
Member

This PR makes it possible to get a better default currency for the fmt_currency() function by using the user-supplied locale value (settable in gt() or fmt_currency(), the latter use can override the earlier). Nearly all locale values are tied to territory that is a country. While some countries can have multiple currencies, we opt for the most-widely used currency (users could always specify the currency code and info_currencies() contains all supported currencies used in the package).

Fixes: #1346

@netlify
Copy link

netlify bot commented Jun 10, 2023

Deploy Preview for quarto-gt-examples failed.

Name Link
🔨 Latest commit ae8ee7d
🔍 Latest deploy log https://app.netlify.com/sites/quarto-gt-examples/deploys/64861ff9ec19230008299925

@rich-iannone rich-iannone merged commit 4f9b9fe into master Jun 11, 2023
13 of 18 checks passed
@rich-iannone rich-iannone deleted the add-currency-default-with-locale branch June 11, 2023 19:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

allow user to set a preferred currency
1 participant