startsWith method
Implementation
bool startsWith(String query, CountryLocalizations? localizations) {
String _query = query;
if (query.startsWith("+")) {
_query = query.replaceAll("+", "").trim();
}
return phoneCode.startsWith(_query.toLowerCase()) ||
name.toLowerCase().startsWith(_query.toLowerCase()) ||
countryCode.toLowerCase().startsWith(_query.toLowerCase()) ||
(localizations
?.countryName(countryCode: countryCode)
?.toLowerCase()
.startsWith(_query.toLowerCase()) ??
false);
}