(Translated by https://www.hiragana.jp/)
GitHub - IftekherSunny/go_country: Country is the package that helps you to get country name and dialling code by the country ISO 3166-1 Alpha-2 code.
Skip to content

Country is the package that helps you to get country name and dialling code by the country ISO 3166-1 Alpha-2 code.

License

Notifications You must be signed in to change notification settings

IftekherSunny/go_country

Repository files navigation

Country

Project status Build Status cover.run go Go Report Card GoDoc License

Country is the package that helps you to get country name and dialing code by the country ISO 3166-1 Alpha-2 code.

Installation Process

 go get github.com/IftekherSunny/go_country

Basic Uses

Get all countries name and dialing code
country := country.NewCountry()

countries := country.All()
Get a country name and dialing code
country := country.NewCountry()

countryDetails, _ := country.Get("BD")
Get multiple countries name and dialing code
country := country.NewCountry()

countries, _ := country.Get([]string{"BD", "US"})
Get a country name
country := country.NewCountry()

name, _ := country.GetName("BD")
Get a country dialing code
country := country.NewCountry()

dialingCode, _ := country.GetDialingCode("BD")

Test

Run tests
go test -v

License

This package is licensed under the MIT License

About

Country is the package that helps you to get country name and dialling code by the country ISO 3166-1 Alpha-2 code.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages