在html頁面填入字符串,\n換行不起作用,怎麼辦?

CSS white-space 屬性 在white-space屬性中,有上圖幾個值可供選擇,我們可以在DOM元素中使用white-space: pre-line; 這樣在html頁面填入字符串,\n換行就起作用了。
相關文章
相關標籤/搜索