Categories JavaScript Answers How to create a new line in JavaScript? Post author By John Au-Yeung Post date September 5, 2022 No Comments on How to create a new line in JavaScript? Spread the love To create a new line in JavaScript, we call document.write. For instance, we write document.write("<br>"); to add a br line break element. Or we write document.write("\n"); to add a new line Related Posts How to create a JavaScript string with new line but not using \n?Sometimes, we want to create a JavaScript string with new line but not using \n.… How to create line breaks in console.log() in Node.js and JavaScript?Sometimes, we want to create line breaks in console.log() in Node.js and JavaScript. In this… How to create structs in JavaScript?Sometimes, we want to create structs in JavaScript. In this article, we'll look at how… By John Au-Yeung Web developer specializing in React, Vue, and front end development. View Archive → ← How to get the next / previous element using JavaScript? → How to record audio to file with HTML5 and JavaScript? Leave a Reply Cancel replyYour email address will not be published. Required fields are marked *Comment * Name * Email * Website Save my name, email, and website in this browser for the next time I comment. Current ye@r * Leave this field empty