Q:

document.ready event

document.addEventListener("DOMContentLoaded", function() {
  // code
});
9
$( document ).ready(function() {
    console.log( "ready!" );
});
2
document.addEventListener("DOMContentLoaded", function(event) { 
  //we ready baby
});
31
$(function(){
  // equal to $( document ).ready(function() {
});
  
9
// A $( document ).ready() block.
$( document ).ready(function() {
    console.log( "ready!" );
});
1

  
    $(document).ready(function(){
  $("button").click(function(){
    $("p").slideToggle();
  });
 });
  
 
0

New to Communities?

Join the community