渲染 html 表格最快的方法是什么?
我看到过关于使用 table-layout:fixed
。我看到过关于预先定义 col 宽度的评论,也看到过很多关于避免使用表格(尤其是嵌套表格)并使用一些 CSS 解决方案而不是表格的评论。
是否有一个商定的记录解决方案来尽可能快地渲染 html 表格?
另外,如果有一种更快的替代方案,那就太好了。
I have seen comments on using table-layout: fixed
. I have seen comments on defining col widths upfront and also lots of comments on avoiding table especially nested tables and use some CSS solution instead of tables.
Is there an agreed documented solution for rendering an html table as fast as possible?
Also, if there is an alternative that is faster that would be great as well.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我想说的是,不用担心,表格在所有浏览器上都可以很好地呈现,而且速度不是问题。话虽如此,如果只是为了坚持 div 的布局,请将它们用于表格数据。
I would say don't sweat it, tables will render fine across all browsers, and speed is not an issue. That being said, use them for tabular data, if it's just for layout stick to divs.