So I have this table below. And I want to get the text inside td.am-receipt-price but without getting the span text included.
<table>
<tbody>
<tr>
<td class="am-receipt-price">
<span class="am-receipt-discounted-price"><del>price 1</del></span>
price 2
</td>
</tr>
</tbody>
</table>
console.log ( $(".am-receipt-price").text() ) would also return the text inside the span. I have tried .remove("span") but it wont work.
Am I missing any selector that I have not tried yet? thanks in advance.