mam długi łańcuch, który buduję użyciu ES6 ciągi szablonów, ale chcę go mieć bez przerwy liniowych:Szablon Struny ES6 zapobiec podziały wiersza
var string = `As all string substitutions in Template Strings are JavaScript
expressions, we can substitute a lot more than variable names.
For example, below we can use expression interpolation to
embed for some readable inline math:`
console.log(string);
Wynik:
As all string substitutions in Template Strings are JavaScript
expressions, we can substitute a lot more than variable names.
For example, below we can use expression interpolation to
embed for some readable inline math:
My oczekiwanie:
As all string substitutions in Template Strings are JavaScript expressions, we can substitute a lot more than variable names. For example, below we can use expression interpolation to embed for some readable inline math:
uciec przed linią podziału z ukośnikiem '\\' i zniknie w wynikach, nawet w łańcuchach szablonów. – dandavis