How to freeze web browser's repaints while changing visibility of elements?

后端 未结 2 1688
攒了一身酷
攒了一身酷 2020-12-09 10:52

I\'m by far no JS developer (in fact, hardly developer at all :) but I wanted to try to write a small Greasemonkey script to hide few elements on a certain webpage. Once I\'

2条回答
  •  情书的邮戳
    2020-12-09 11:34

    You can use cloneNode. After cloning you can do all manipulations over the clone and than replace original node. This will prevent your content from blinking when display:none like J-P proposed.

提交回复
热议问题