title: How can I apply a class to all words in a paragraph tag which are in an array?
body: <p>Let's say I have a paragraph defined as</p>
  
  <pre><code>&lt;p&gt;Here is a short paragraph of text which has repeating words. Words such &lt;br&gt;
  as these will have a span around them which changes a property of words in a &lt;br&gt;
  paragraph.
  &lt;/p&gt;
  </code></pre>
  
  <p>with a script that has an array of words that I want to apply this class to. </p>
  
  <pre><code>var blueWords = ["paragraph", "words", "which", "a"];
  </code></pre>
  
  <p>How can I iterate through each item inside the paragraph and append a</p>
  
  <pre><code>&lt;span color="blue"&gt;&lt;/span&gt;
  </code></pre>
  
  <p>around those predefined words in the blueWords array? This may be easily done in jQuery, but I am unsure how to go about doing this.</p>