Answer the question
In order to leave comments, you need to log in
How to turn off whitespace removal in Angular?
Good evening!
There is this code:
<div class="col-xs-6 ta-r">
<h4>License:</h4> <p>Standard</p>
</div>
<div class="col-xs-6 ta-r"><h4>License:</h4><p>Standard</p></div>
License:
Standard
"angularCompilerOptions": {
"preserveWhitespaces": false
}
Answer the question
In order to leave comments, you need to log in
Default is false, unless overridden in compiler options
"preserveWhitespaces": true
The positioning of elements on the page should not depend on spaces and enters in the layout. Do customization with css. You, apparently, made it <h> и <p>
inlan, which, judging by the context, is incorrect. Make them как <label> и как <span>
accordingly, add the necessary css rules for size and weight, add margin-left. And then you don't have to look for crutches to remove spaces in the markup.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question