jQuery 的 $( document ).ready() 函数

这个函数在在页面载入完成后执行的。

可以定义为下面:$( document ).ready(function() { console.log( "ready!" ); });上面语句的意思是在页面载入完成后显示 ready。