Skip to content

Instantly share code, notes, and snippets.

@JohnMarkT
Created January 20, 2022 16:37
Show Gist options
  • Save JohnMarkT/11d9942926a4417cdf70797b91b5666d to your computer and use it in GitHub Desktop.
Save JohnMarkT/11d9942926a4417cdf70797b91b5666d to your computer and use it in GitHub Desktop.
Case insensitive match
function ciMatch(prop = '', str = '') {
return str.localeCompare(prop, 'en', { sensitivity: 'base' }) === 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment