No commit activity in last 3 years
No release in over 3 years
ISO country code and currency library
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
 Dependencies

Development

~> 3.5.3

Runtime

~> 13.0.6
~> 2.0.4
 Project Readme

CountryCurrency

DESCRIPTION:

Provides ISO codes, names and currencies for countries.

Ruby Version >= 2.4

USE:

# Search by country (Argentina)
country = CountryCurrency.find('AR')        # Alpha2
country = CountryCurrency.find('ARG')       # Alpha3
country = CountryCurrency.find('Argentina') # Iso name

# Attributes
country.currency        # => "ARS"
country.currency_symbol # => "$"
country.alpha2          # => "AR"
country.alpha3          # => "ARS"
country.calling         # => "+54" phone number prefix

# Search by country (United States)
country = CountryCurrency.find('US')            # Alpha2
country = CountryCurrency.find('USA')           # Alpha3
country = CountryCurrency.find('United States') # Iso name

# Attributes
country.currency        # => "USD"
country.currency_symbol # => "u$d"
country.alpha2          # => "US"
country.alpha3          # => "USA"
country.calling         # => "+1" phone number prefix

console:

$ rake console

test:

$ rake test