Reputation: 369
I found that sometimes this code returns NotFoundError: An attempt was made to reference a Node in a context where it does not exist.
$('a').replaceWith(function() {
return $.text([this]);
});
Is it complaining about a case when the anchor does not have any text node? perhaps a child HTML element?
Upvotes: 2
Views: 81