好久没写博客了 都是用印象笔记 以后都纪录一份到博客吧
html
<div class="illness-timeline-content-detail" [innerHtml] = "abc | safe: 'html'"></div>
ts
public abc: any = '病程记录内容:经过几天的治疗,现在情况已经好转\r\n估计过几天就能出院了';
css
&-content {
position: relative;
font-size: 14px;
&-detail {
white-space: pre-wrap;
}
}
效果如下