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

Add new intl-tel-input-options parameter: "watch", for two-way binding ngModel in realtime & update compatibility for jQuery 3^. #26

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

alexandria-p
Copy link

@alexandria-p alexandria-p commented Aug 1, 2018

[This PR also fixes compatibility with jQuery 3^]

This update allows for the user to set 'watch' to true in the intl-tel-input-options. This corrects how model value updates and solves any functionality that is dependent on two-way binding to the ngModel value. If watch is set to false, functionality reverts back to the way it was previously where the ngModel value only updates in $scope once the phone number is found to be valid and is 'undefined' if the phone number is invalid.

Using 'watch' only works for Angular.js v1.3 or higher.

Model value will update in real-time to fix how $scope.watch is called.
Model value will update in real-time to fix how $scope.watch is called.
@alexandria-p alexandria-p changed the title Add new intl-tel-input-options parameter: "watch", for two-way binding ngModel in realtime. Add new intl-tel-input-options parameter: "watch", for two-way binding ngModel in realtime & update compatibility for jQuery 3^. Aug 1, 2018
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.

1 participant