Long word wrap in nested tables

后端 未结 3 571
予麋鹿
予麋鹿 2021-01-28 07:02

I\'m trying to wrap a long word. I have seen this post : How to prevent long words from breaking my div?

It works great in a simple case like this :

.wra         


        
3条回答
  •  臣服心动
    2021-01-28 07:58

    table is taking the table-layout: auto; by default so as per contents increase the width also increases so you need to set table-layout to fixed.

    table{
        table-layout: fixed;
    }
    

    demo

提交回复
热议问题