jQuery slideDown()第一次没有工作

use*_*119 5 jquery

为什么slideDown()第一次不能工作?

$('#lnkInfo').click(function (e) {
    e.preventDefault();
    $(this).blur();
    if ($(this).text() == 'More info') {
        $('#spnMoreInfo').slideDown(200);
        $(this).text('Less info');
    }
    else if ($(this).text() == 'Less info') {
        $('#spnMoreInfo').slideUp(200);
        $(this).text('More info');
    }
});
Run Code Online (Sandbox Code Playgroud)

jsfiddle在这里

编辑:使用Firefox 22.0

and*_*axo 7

更改<span id="spnMoreInfo" ...>div.jQuery在显示它之前无法弄清楚它的高度.这就是它立即显示而不是滑动的原因.

在这里改进了小提琴.