JSFiddle - React, Tailwind, and code Playground
HTML
<div>
<p>
<em>28.11.2014</em>
<img></img>
Testtext
<span>
<i>Testtext</i>
Testtext
</span>
</p>
</div>
JavaScript
$('div').find("*").contents().filter(function() {
return this.nodeType == 3;
}).remove();