Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p><code>stopPropagation</code> will prevent any <strong>parent</strong> handlers from being executed <code>stopImmediatePropagation</code> will prevent any parent handlers <strong>and also</strong> any <strong>other</strong> handlers from executing </p> <p>Quick example from the <a href="http://api.jquery.com/event.stopImmediatePropagation/" rel="noreferrer">jquery documentation:</a> </p> <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false"> <div class="snippet-code"> <pre class="snippet-code-js lang-js prettyprint-override"><code>$("p").click(function(event) { event.stopImmediatePropagation(); }); $("p").click(function(event) { // This function won't be executed $(this).css("background-color", "#f00"); });</code></pre> <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"&gt;&lt;/script&gt; &lt;p&gt;example&lt;/p&gt;</code></pre> </div> </div> </p> <p>Note that the order of the event binding is important here!</p> <p><div class="snippet" data-lang="js" data-hide="true" data-console="true" data-babel="false"> <div class="snippet-code snippet-currently-hidden"> <pre class="snippet-code-js lang-js prettyprint-override"><code>$("p").click(function(event) { // This function will now trigger $(this).css("background-color", "#f00"); }); $("p").click(function(event) { event.stopImmediatePropagation(); });</code></pre> <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"&gt;&lt;/script&gt; &lt;p&gt;example&lt;/p&gt;</code></pre> </div> </div> </p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload