“JS Multiline String с переменными” Ответ

JavaScript Multiline String


// OPTION 1
var MultilineString = `This
is 
a multiline 
string`; // Note: use the template quotation marks above the tab key

// OPTION 2
var MultilineString = 'This \n\
is \n\
a multiline \n\
string'; // Note: use the "\n\" as a newline character
Jacques_Kirstein

JS Multiline String с переменными

const htmlString = `${user.name} liked your post about strings`;
FishBrawler

JavaScript Multiline String

    // Creating multi-line string
    var str = `<div class="content">
                  <h1>This is a heading</h1>
                  <p>This is a paragraph of text.</p>
               </div>`;
    
    // Printing the string
    document.write(str);
Anthony Smith

Ответы похожие на “JS Multiline String с переменными”

Вопросы похожие на “JS Multiline String с переменными”

Больше похожих ответов на “JS Multiline String с переменными” по JavaScript

Смотреть популярные ответы по языку

Смотреть другие языки программирования