title: jQuery - get only parent element text without children
body: <p>I have a web page I'm scraping, and the text I'm looking for is inside a <code>span</code> that contains another <code>span</code></p>
  
  <pre><code>&lt;div class="someParentDiv"&gt;
    &lt;span&gt;this is the text I want   
      &lt;span class="childSpanClass"&gt;I don't want this text&lt;/span&gt;
    &lt;/span&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>I'm trying to get the text I want with a jQuery selection, but when I get the elemnt's text with <code>text()</code>, I will get also the child span's text, which I don't want.</p>
  
  <p>I managed to get only the text I want with</p>
  
  <pre><code>$('div.someParentDiv span').remove('.childSpanClass')
  </code></pre>
  
  <p>but it seems a little backwards to me (<a href="http://jsfiddle.net/sz34ar7o/1/" rel="nofollow">see example</a>), and I'm wondering if there's a better, nicer way to do it.
  Any ideas?</p>