{"id":15038697,"url":"https://github.com/ar4n3/countrycallingcodes","last_synced_at":"2026-02-06T18:09:45.056Z","repository":{"id":56906777,"uuid":"101811838","full_name":"Ar4n3/CountryCallingCodes","owner":"Ar4n3","description":"A simple and easy way to get the international calling code and Emoji flag from a selected Country. Demos are provided in Objective-C and Swift.","archived":false,"fork":false,"pushed_at":"2020-05-04T15:00:05.000Z","size":145,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-13T15:16:40.234Z","etag":null,"topics":["framework","objective-c","swift3"],"latest_commit_sha":null,"homepage":"","language":"Objective-C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Ar4n3.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-08-29T22:20:19.000Z","updated_at":"2020-06-14T17:23:04.000Z","dependencies_parsed_at":"2022-08-20T19:20:24.798Z","dependency_job_id":null,"html_url":"https://github.com/Ar4n3/CountryCallingCodes","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ar4n3%2FCountryCallingCodes","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ar4n3%2FCountryCallingCodes/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ar4n3%2FCountryCallingCodes/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ar4n3%2FCountryCallingCodes/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Ar4n3","download_url":"https://codeload.github.com/Ar4n3/CountryCallingCodes/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243428434,"owners_count":20289317,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["framework","objective-c","swift3"],"created_at":"2024-09-24T20:39:44.206Z","updated_at":"2026-02-06T18:09:45.013Z","avatar_url":"https://github.com/Ar4n3.png","language":"Objective-C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CountryCallingCodes\n\n\n[![Build Status](https://app.bitrise.io/app/fe0994beb7f761fb.svg?token=PyJS3u6SCGVaKcnXb5Dfiw)](https://www.bitrise.io/app/fe0994beb7f761fb) [![codecov](https://codecov.io/gh/Ar4n3/CountryCallingCodes/branch/master/graph/badge.svg)](https://codecov.io/gh/Ar4n3/CountryCallingCodes) [![pod](https://cocoapod-badges.herokuapp.com/v/CountryCallingCodes/0.1.1/badge.png)](https://cocoapods.org/pods/CountryCallingCodes) [![license](https://cocoapod-badges.herokuapp.com/l/CountryCallingCodes/badge.png)](https://cocoapods.org/pods/CountryCallingCodes)\n\n\n\n\nA simple and easy way to get the international calling code and Emoji flag from a selected Country. Demos are provided in Objective-C and Swift.\n\n## Installation\n\nYou can download this project, or you can install it via Cocoapods:\n\n```cocoapods\nsource 'https://github.com/CocoaPods/Specs.git'\nplatform :ios, '10.0'\n\ntarget 'TargetName' do\npod 'CountryCallingCodes'\nend\n```\n\n## How to use\n\n### Objective-C\n\nGet the default data for your device locale (e.g. flag =\u003e :es:, code =\u003e \"+34\")\n\n```objective-c\n[[CountryCallingCode sharedInstance] setDelegate:self];\nNSString *buttonString = [NSString stringWithFormat:@\"%@\\t%@\", [CountryCallingCode sharedInstance].flag, [CountryCallingCode sharedInstance].code];\n[_countryButton setTitle:buttonString forState:UIControlStateNormal];\n```\n\nTo select another country, make a segue to storyboard reference and on your delegate implement:\n\n```objective-c\n#pragma mark - Delegate Methods\n\n- (void)updateCountryData {\n    NSString *buttonString = [NSString stringWithFormat:@\"%@\\t%@\", [CountryCallingCode sharedInstance].flag, [CountryCallingCode sharedInstance].code];\n    [_countryButton setTitle:buttonString forState:UIControlStateNormal];\n}\n\n```\n\n### Swift\n\nGet the default data for your device locale (e.g. flag =\u003e :es:, code =\u003e \"+34\")\n\n```swift\nCountryCallingCode.sharedInstance().delegate = self\nlet buttonString = String.init(format: \"%@\\t%@\", CountryCallingCode.sharedInstance().flag, CountryCallingCode.sharedInstance().code)\ncountryButton.setTitle(buttonString, for: .normal)\n```\n\nTo select another country, make a segue to storyboard reference and on your delegate implement:\n\n```swift\n//MARK: Delegate methods\nfunc updateCountryData() {\n   let buttonString = String.init(format: \"%@\\t%@\", CountryCallingCode.sharedInstance().flag, CountryCallingCode.sharedInstance().code)\n   countryButton.setTitle(buttonString, for: .normal)\n}\n\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Far4n3%2Fcountrycallingcodes","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Far4n3%2Fcountrycallingcodes","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Far4n3%2Fcountrycallingcodes/lists"}