Performance differences between visibility:hidden and display:none

前端 未结 8 1081
一生所求
一生所求 2020-11-27 04:34

I want to simplify things in my jQuery Backbone.js web application. One such simplification is the behavior of my menu and dialog widgets.

Previously I created the

8条回答
  •  南笙
    南笙 (楼主)
    2020-11-27 05:00

    Well, visibility:none still uses the space of the div. So you could maybe skip the positioning part because its place is already allocated (and by that get a better performance).

    But I somehow guess that you need your display:none approach to allocate space correctly when the "show" event is triggered.

提交回复
热议问题