Skip to main content
add example
Source Link
rogerdpack
  • 65.5k
  • 38
  • 278
  • 396

If you are using jQuery,

$(function() {...});

is equivalent to

$(document).ready(function () { })

or another short hand:

$().ready(function () { })

See What event does JQuery $function() fire on? and https://api.jquery.com/ready/

If you are using jQuery,

$(function() {...});

is equivalent to

$(document).ready(function () { })

See What event does JQuery $function() fire on?

If you are using jQuery,

$(function() {...});

is equivalent to

$(document).ready(function () { })

or another short hand:

$().ready(function () { })

See What event does JQuery $function() fire on? and https://api.jquery.com/ready/

replaced http://stackoverflow.com/ with https://stackoverflow.com/
Source Link
URL Rewriter Bot
URL Rewriter Bot

If you are using jQuery,

$(function() {...});

is equivalent to

$(document).ready(function () { })

See What event does JQuery $function() fire on?What event does JQuery $function() fire on?

If you are using jQuery,

$(function() {...});

is equivalent to

$(document).ready(function () { })

See What event does JQuery $function() fire on?

If you are using jQuery,

$(function() {...});

is equivalent to

$(document).ready(function () { })

See What event does JQuery $function() fire on?

Source Link
Benjamin Crouzier
  • 41.5k
  • 47
  • 177
  • 239

If you are using jQuery,

$(function() {...});

is equivalent to

$(document).ready(function () { })

See What event does JQuery $function() fire on?