When updating onlyCountries after been initialized the component (e.g.: loading from backend) the new values of onlyCountries does not get updated in ngx-intl-tel-input.
Checking in ngOnChanges for changes['onlyCountries'] and updating as necessary solved the issue:
if (changes['onlyCountries']) {
this.allCountries = this.allCountries.filter((c) => this.onlyCountries.includes(c.iso2));
}
When updating onlyCountries after been initialized the component (e.g.: loading from backend) the new values of onlyCountries does not get updated in ngx-intl-tel-input.
Checking in ngOnChanges for changes['onlyCountries'] and updating as necessary solved the issue:
if (changes['onlyCountries']) { this.allCountries = this.allCountries.filter((c) => this.onlyCountries.includes(c.iso2)); }