Bootstrap table 元素列内容超长自动折行显示方法?

时间:2023-03-09 17:10:27
Bootstrap table 元素列内容超长自动折行显示方法?

共需要四步:

1.在table元素的父容器div加上:class="table-responsive"

3.设置表头th的width:<th width="20%"></th>

4.在可能出现内容超长的td上加上样式:<td style="word-break:break-all; word-wrap:break-word; white-space:inherit"></td>

完成设置!!!