Javascript replace new line with br tag (줄바꿈을 br tag로 변환)

function replaceNewLineWithBr(text) {
return text.replace(/(?:\r\n|\r|\n)/g, "<br />");
}

댓글

이 블로그의 인기 게시물

mongoDB admin 권한 설정방법 How to enable access control for mongo DB

Install pm2 via yarn globally

Install node and yarn on Linux