[JQUERY] setTimeout 사용법
2022.02.03
프로세스가 순차적으로 수행하는데, 상위 프로세스의 로딩이 오래걸려 하위 프로세스가 먼저 실행되어 원하는 결과값을 못가져오는 경우 setTimeout()을 걸어 지연시키고자 사용
setTimeout( function() { source, interval);
setTimeout(function(){ alert("Hello"); }, 3000 );
setTimeout( function(){
$( ".tableData" ).each(function( index ) {
for(var i = 0; i < indexNo.length; i++){
if(indexNo[i] != index) {
$(this).css("display", "none");
}else {
$(this).css("display", "block");
}
}
});
}, 1000 ); //1000은 1초
작성자
꿘쓰
작성일
2022.02.03
