{"id":20414297,"url":"https://github.com/gauravsoni119/ng2-tel-input","last_synced_at":"2025-04-07T12:11:04.726Z","repository":{"id":11630810,"uuid":"70174901","full_name":"gauravsoni119/ng2-tel-input","owner":"gauravsoni119","description":null,"archived":false,"fork":false,"pushed_at":"2022-12-03T05:31:57.000Z","size":313,"stargazers_count":56,"open_issues_count":54,"forks_count":58,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-03-31T11:04:22.314Z","etag":null,"topics":["angular","gulp","intltelinput","typescript"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/gauravsoni119.png","metadata":{"files":{"readme":"README.md","changelog":"changelog.md","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":"2016-10-06T17:05:50.000Z","updated_at":"2024-09-18T08:22:30.000Z","dependencies_parsed_at":"2023-01-13T21:00:48.348Z","dependency_job_id":null,"html_url":"https://github.com/gauravsoni119/ng2-tel-input","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/gauravsoni119%2Fng2-tel-input","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gauravsoni119%2Fng2-tel-input/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gauravsoni119%2Fng2-tel-input/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gauravsoni119%2Fng2-tel-input/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gauravsoni119","download_url":"https://codeload.github.com/gauravsoni119/ng2-tel-input/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247648977,"owners_count":20972945,"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":["angular","gulp","intltelinput","typescript"],"created_at":"2024-11-15T06:08:53.342Z","updated_at":"2025-04-07T12:11:04.692Z","avatar_url":"https://github.com/gauravsoni119.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003e This repository is no longer maintained.\u003c/h1\u003e\n\n# Angular 2+ wrapper for intl-tel-input\n\n# Installation\n\nRun following command to install ng2-tel-input\n\n```sh\nnpm install ng2-tel-input intl-tel-input --save\n```\n\nAfter install, you need to add **intlTelInput.css**, **intlTelInput.min.js**, **utils.js**.\n\nIn case of @angular/cli, add 2 files in your `angular.json`. \n\nFor example,\n\n- Include **intlTelInput.css** in \"styles\" at your `angular.json` file  :\n```\n  \"styles\": [\n    ...\n    \"node_modules/intl-tel-input/build/css/intlTelInput.css\",\n    ...\n  ]\n```\n\n- Include **intlTelInput.min.js**, **utils.js** in \"scripts\" at your `angular.json` file  :\n```\n  \"scripts\": [\n    ...\n    \"node_modules/intl-tel-input/build/js/intlTelInput.min.js\"\n    ...\n  ]\n```\n\n\nNow add Ng2TelInputModule into your AppModule. For example,\n\n```js\nimport {Ng2TelInputModule} from 'ng2-tel-input';\n```\n\nOnce done, we are ready to use this library.\n\n# How to use?\n\nIn order to use this directive, you need to add \"ng2TelInput\" directive with \"[ng2TelInputOptions]\" options to your text field. For example,\n\n```html\n\u003cinput type=\"text\"\n  ng2TelInput\n  [ng2TelInputOptions]=\"{initialCountry: 'in'}\"\n  (hasError)=\"hasError($event)\"\n  (ng2TelOutput)=\"getNumber($event)\"\n  (intlTelInputObject)=\"telInputObject($event)\"\n  (countryChange)=\"onCountryChange($event)\" /\u003e\n```\n\n# Note\n**(intlTelInputObject)** returns **intl-tel-input** instance.\nBy default this package get **utils.js** from below link:-\nhttps://cdnjs.cloudflare.com/ajax/libs/intl-tel-input/16.0.1/js/utils.js\nBut you can also provide your utilsScript file by using below options:-\n\n[ng2TelInputOptions]=\"{initialCountry: 'in', utilsScript: 'node_modules/intl-tel-input/build/js/utils.js'}\"\n\n# How to use this instance?\nYou can use it perform any functionality that is available on intl-tel-input plugin. **For example**, in your component,\n```\ntelInputObject(obj) {\n    console.log(obj);\n    obj.setCountry('in');\n  }\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgauravsoni119%2Fng2-tel-input","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgauravsoni119%2Fng2-tel-input","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgauravsoni119%2Fng2-tel-input/lists"}