Open StephenHaney opened 2 years ago
Thank you - me too! If the first childnode is a div
an extra new line is added. So I just added an additional condition (i !== 0):
if (childNode.nodeName === 'DIV' && isOnFreshLine === false && i !== 0) {
// Divs create new lines for themselves if they aren't already on one
newValue += '\n'
}
Thanks
Thank you. I'm using it!