jquery animate的一个疑惑

$('#example').slideUp('slow', function () {
$(this).hide();
});
======分割线======
$('#example').slideUp('slow').hide();
这样是有差别的;第二种写法不会有动画效果;
正常逻辑;动画结束后让这个('#example')元素消失;没毛病啊;

========分割线========
再来看这个;
$('#example').slideDown('slow').show();
这样写是有动画效果的;但是;
动画执行完之后,让元素本身显现出来;想想都可笑啊;

=======分割线=======
猜测:$('#example').hide();/show();
这两个方法会提前;会不会与变量提升有关呢?
上着班的;有时间再研究一波;

posted @ 2017-06-15 11:48  流年之外天空蓝  阅读(126)  评论(0编辑  收藏  举报