<textarea id =“article_content”rows =“10”cols =“100”placeholder =“请输入文章内容”value =“”> </ textarea> <br/>
const article_content = document.querySelector('#article_content');
var content = article_content.value.replace(/ \ r / g,'');
if(content!='')
{
content ='<p>'+ content.replace(/ \ n * $ / g,'')。replace(/ \ n / g,'</ p> <p>' )+'</ p>';
}