difference between "$(function()" and "$(document).ready"
Posted
by choise
on Stack Overflow
See other posts from Stack Overflow
or by choise
Published on 2010-05-12T15:15:31Z
Indexed on
2010/05/12
15:24 UTC
Read the original article
Hit count: 242
Normally is use
$(document).ready(function() {
// do something
});
to do something after dom is loaded.
in the last time i often see
$(function() {
// do something
});
that also works. whats the difference?
© Stack Overflow or respective owner