반응형

if(window.console!=undefined) console.log.bind()


<script type="text/javascript">
if(window.console!=undefined){
    setTimeout(console.log.bind(console,"%cTISTORY","font:8em Arial;color:#EC6521;font-weight:bold"),0);
    setTimeout(console.log.bind(console,"%c  나를 표현하는 블로그","font:2em sans-serif;color:#333;"),0);
}
</script>








.

반응형
반응형

javascript - setTimeOut

 

 

Example

Display an alert box after 3 seconds (3000 milliseconds):

 

setTimeout(function(){ alert("Hello"); }, 3000);

 

Definition and Usage

The setTimeout() method calls a function or evaluates an expression after a specified number of milliseconds.

Tip: 1000 ms = 1 second.

Tip: The function is only executed once. If you need to repeat execution, use the setInterval() method.

Tip: Use the clearTimeout() method to prevent the function to run. 

반응형

+ Recent posts