As you may know the hook with commenting whitespaces between ‘display: inline-block’ elements.
What do you think of such a solution:
<div style="display:inline-block">Content 1</div><!--
---><div style="display:inline-block">Content 2</div><!--
---><div style="display:inline-block">Content 3</div>
I want to use ‘—>’ in the end to keep code finely indentated without spaces ( I use four-digit tab ).
Also a question: in Sublime text 2 it does not understand that comment is closed with ‘—>’ and paint all the code after as commented and does not highlight it. Is there an easy way around it?
Thank you.
See the HTML 5 specification on comments:
You are ending the comment text with a
-which is not allowed. This is confusing the syntax highlighter of your editor.Using
-->instead of--->will fix it. (I have tested this in my copy of subl2).