jQuery stop(true, true) to jump to end of all animations in queue

前端 未结 4 1497
野性不改
野性不改 2021-02-14 08:19

I have been using jQuery\'s stop(true, true) method to clear running animations so the next one starts immediately. I noticed that the first parameter, clearQ

4条回答
  •  北恋
    北恋 (楼主)
    2021-02-14 08:51

    I also notice from the documentation of the .finish() method in jQuery 1.9 that

    Animations may be stopped globally by setting the property $.fx.off 
    to true. When this is done, all animation methods will immediately 
    set elements to their final state when called, rather than displaying an effect.
    

    There is also a nice demo of the various methods on the .finish() documentation page.

提交回复
热议问题