Add line break within tooltips

后端 未结 27 2500
北恋
北恋 2020-11-28 02:23

How can line breaks be added within a HTML tooltip?

I tried using
and \\n within the tooltip as follows:



        
27条回答
  •  [愿得一人]
    2020-11-28 02:34

    Using .html() instead of .text() worked for me. For example

    .html("This is a first line." + "
    " + "This is a second line.")

提交回复
热议问题