This repository was archived by the owner on Dec 19, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 222
Remove unnecessary whitespace that is rendered for non markup content #485
Comments
@ajaybhargavb Please also consider this (#423) related suggestion for minifying HTML at compile time. |
ajaybhargavb
added a commit
that referenced
this issue
Sep 10, 2015
- #485 - Using a flag to consume whitespace and newline at the end of a verbatim block - Added tests to validate nested blocks
ajaybhargavb
added a commit
that referenced
this issue
Sep 10, 2015
- #485 - Using a flag to consume whitespace and newline at the end of a verbatim block - Added tests to validate nested blocks
ajaybhargavb
added a commit
to aspnet/Mvc
that referenced
this issue
Sep 11, 2015
ajaybhargavb
added a commit
to aspnet/Mvc
that referenced
this issue
Sep 11, 2015
In ASP.NET Core project in my .cshtml when I use
I get following as a result:
There is a space before full stop symbol. How can I get rid of it? Is my only option to inline it like so:
|
@NickAb I was able to reproduce your issue with:
And even
Would you mind opening a separate issue with what you have? Also, as a work around this works (still ugly 😢 ):
|
Actually, nm @NickAb this issue should be reopened. The browser was being kind rendering a space, the HTML is actually a newline which should have been covered by this issue. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Extra new lines from razor comments has been removed in #428. But we still need to handle unnecessary whitespace in other places.
From @danroth27:
We've decided to be smart about removing whitespace for any non-HTML content that occupies the entire line. So in addition to @RehanSaeed's example #428 (comment), the following example:
@{ } <!DOCTYPE html>
Should render just the doctype without any leading whitespace (which would be invalid). Also:
Should not render a line with four spaces before the list item.
cc' @NTaylorMullen
The text was updated successfully, but these errors were encountered: