Answer the question
In order to leave comments, you need to log in
How to remove extra indentation in a JavaScript template?
I think that the problem is not so common due to the fact that most users use React + JSX, Vue and Angular. But often in VanilaJS I write code like this
function getTemplate() {
const html = `<div>
<span>Привет</span>
</div>`;
return html;
}
function getTemplate() {
const html = `<div>
<span>Привет</span>
</div>`;
return html;
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question