title: Filtering through an array to match the text (jQuery / Javascript)
body: <p>I have an unordered list called <code>$myList</code>. Every time a string (<code>$entry</code>) is entered into an input, I want to run through the list to see if that string is already in the list. If it is, I want to remove the list item that contains the matching string. Either way, the new string gets added and becomes a new list item.</p>
  
  <p>Here's the most recent thing I tried:</p>
  
  <pre><code>$myList.text().filter($entry).remove();
  
  
  $myList.append($entry);
  </code></pre>
  
  <p>It doesn't like that I'm doing <code>.text().filter()</code>, but none of the other things I've tried have worked either.</p>
  
  <p>What's a simple way to accomplish this?</p>