title: How to search for specific string value thats has corresponding text
body: <p>I'm trying to check for a value that matches in an array of strings.</p>
  <p>So something like this works</p>
  <pre><code>const usernames = ['owlman', 'neo', 'trinity'];
  const name = 'neo'
  
  if(usernames.indexOf(name) &gt; -1 ){
    console.log('you found me')
  }
  else{
    console.log('no luck finding user')
  }
  </code></pre>
  <p>but what happens if you have a textarea comment, and you want to mention a user with comment data so you do something like this</p>
  <pre><code>const usernames = ['owlman', 'neo', 'trinity'];
  const name = '@neo you look like the one!'
  
  if(usernames.indexOf(name) &gt; -1 ){
    console.log('you found me')
  }
  else{
    console.log('no luck finding user') // this gets callee
  }
  </code></pre>
  <p>demo</p>
  <p><a href="https://jsbin.com/gepiqopiri/edit?js,console" rel="nofollow noreferrer">https://jsbin.com/gepiqopiri/edit?js,console</a></p>
  <p>How can i search for a specific value that is an array when there is corresponding data along with it . Is <code>indexOf</code> the approach i want to be using ?</p>