p
<div oninput="chDIV()"style="white-space :pre;"contenteditable="true">вставить 1 отступ</div>
<p style="white-space :pre; background:#000; color:#fff"></p>
<script>
function chDIV(){
document.querySelector('p').innerText = document.querySelector('div').innerText.replace(/\n/g,'\\n\n');
}
</script>
почему 1 отступ вниз записанный в элемент через contenteditable ; Равен '\n\n\n'? (а должен, по идее, быть равен одной '\n'...)