使用具有完整功能且没有动画的jQuery show()

问题描述 投票:1回答:1

此问题是jQuery toggle() with no animation...之外的内容>>

为了避免在元素的show上产生动画,我正在尝试替换以下2行

var that = this;
this.$el.show("fast", null, function(){that.updatePosition()});

带有以下内容,

this.$el.show();    
this.updatePosition();

是否有可能在当前元素变为updatePosition之前调用函数visible?如果是,那我应该避免动画的解决方法是什么。

这个问题是对没有动画的jQuery toggle()的补充。为了避免在元素显示时出现动画,我正尝试在以下两行替换var that = this; this。$ el.show(“ fast”,null,...

javascript jquery animation backbone.js
1个回答
3
投票

您可以将持续时间作为0

© www.soinside.com 2019 - 2024. All rights reserved.