I have a rather interesting issue. Content is being build dynamically and creating the following scenario.
<button id="something">
<i class="fa fa-refresh"></i>
Some button text
</button>
What I'm trying to do is replace "some button text" while preserving the Font Awesome tag. I've tried regex and so on, but kind of stuck.
As a note, I've tried .text() and it does replace the text, but also removes the i tag too.