Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

3.1.28 {strip} space between tags #136

Closed
JercSi opened this issue Dec 17, 2015 · 4 comments
Closed

3.1.28 {strip} space between tags #136

JercSi opened this issue Dec 17, 2015 · 4 comments

Comments

@JercSi
Copy link
Contributor

JercSi commented Dec 17, 2015

Template:

{strip}
<ul>
    <li>
        <a href="#">BlaBla</a>
    </li>
    <li>
        <a href="#">BlaBla</a>
    </li>
</ul>
{/strip}

Result in 3.1.27 and previous versions:

<ul><li><a href="#">BlaBla</a></li><li><a href="#">BlaBla</a></li></ul>

Result in 3.1.28 (& master)

<ul> <li> <a href="#">BlaBla</a> </li> <li> <a href="#">BlaBla</a> </li> </ul>

I think there shouldn't be spaces between tags.

@uwetews
Copy link
Contributor

uwetews commented Dec 17, 2015

I considered some input that removing spaces entirely might break poorly implemented CSS display:inline-block elements to be on the save side.
Too much safety???

fetus-hina added a commit to fetus-hina/stat.ink that referenced this issue Dec 19, 2015
@thedotedge
Copy link

For example, space removal is mandatory to avoid breaking the layout in some scenarios (where space introduces extra padding between elements), which was fine prior to 3.1.28.
Besides, semantically it makes sense to strip everything: one handle it manually (via custom function) or refactor CSS to avoid the problem you mention instead.

@uwetews
Copy link
Contributor

uwetews commented Dec 21, 2015

Okay, but would you agree not to strip the content of

<script></script>,  <textarea></textarea  and <pre></pre>

sections?

@uwetews
Copy link
Contributor

uwetews commented Dec 21, 2015

The fix is now in the master branch

@uwetews uwetews closed this as completed Dec 21, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants