2 ms·
> What's the problem with node.parentElement.removeChild(node)? It's node.parentNode.removeChild(node). And the fact that this is even a mistake that can be m
by bzbarsky 10y ago
> What's the problem with node.parentElement.removeChild(node)?
It's node.parentNode.removeChild(node). And the fact that this is even a mistake that can be made, and is made by people all the timem is part of the problem!
"node.remove()" is a lot harder to screw up.