Skip to content

Instantly share code, notes, and snippets.

@CatTail
Created July 3, 2014 10:07
Show Gist options
  • Save CatTail/a29554dc93c8a4dbff7b to your computer and use it in GitHub Desktop.
Save CatTail/a29554dc93c8a4dbff7b to your computer and use it in GitHub Desktop.
handy operator to check if result is -1
var isMatch = ~'this is a text'.indexOf('IS');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment