I have an html snippet:
<label class="col-xs-2 col-lg-2 control-label" for="param_comment">Com­ment</label>
and it renders as:
Com­ment
in Chrome v.29
I expected:
Comment
What is wrong with the soft hyphen?
Update:
I meant:
<label class="col-xs-2 col-lg-2 control-label" for="param_comment">Com­ment</label>
Update 2:
I think it was an SLIM fault: I had:
= label_tag(:"param_comment", "Com­ment", class: "control-label")
now changed to:
= label_tag(:"param_comment", "Com­ment".html_safe, class: "control-label")
So the .html_safe helps.
But is it possible to do the same without ruby code?
The HTML snippet posted contains
Com&shy;ment, so it works as defined. UseCom­mentinstead (or enter the soft hyphen as a character, U+00AD:Comment).