title: How to know if a Javascript Callback is Synchronous or Asynchronous?
body: <p>
  Hi! I am learning about callbacks and I understand that callbacks can be either synchronous or asynchronous.</p>
  
  
  
  <p>I was reading about callbacks on <a href="https://www.w3schools.com/jquery/jquery_callback.asp" rel="noreferrer">https://www.w3schools.com/jquery/jquery_callback.asp</a> and was quite confused.</p>
  
  <p>
  There is this code:</p>
  
  <pre><code>$("button").click(function(){
      $("p").hide("slow", function(){
          alert("The paragraph is now hidden");
      });
  }); 
  </code></pre>
  
  
  
  <p>Can I check if there is a way to know if the above callback is Synchronous or Asynchronous?</p>
  
  <p>I am guessing it is Synchronous above because it has to wait till the "slow" animation is over before the alert comes up. Is it by default in Javascript or Node.js all callbacks are synchronous unless you do something like setTimeOut or process.nextTick?</p>