Remova o texto após <span> e adicione outro texto
Estou tendo problemas com o jQuery tentando remover um texto após a tag <span> para acrescentar outro texto.
Exemplo:
<div id="foo-id">
<span id="span-id">
<i id="icon-id" class="fa fa-square-o"></i>
</span> text..here... (this text needs to be removed)
</div>
Eu sei como acrescentar o texto:
$('#foo-id').after()[0].append('this is a text');
Mas como posso remover / limpar o texto após a tag </ span> para acrescentar uma nova?