title: Click function on div inside div with click function
body: <p>So I wanted to know how you could stop the outer divs click function, and only have the inner divs click function be triggered. But, I want to stay using the $(document).on('click',selector) method for use in my application. I have see a few answers, but none that work with that method. Maybe An oversight by me? </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>$(document).ready(function() {
    $('.Name').text('A veery long namemmmmmmeehhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhheeeee');
    $(document).on("click", ".task", function() {
  
      alert("click");
    });
    $(document).on("click", ".Name", function() {
  
      alert("click");
    });
  });</code></pre>
  <pre class="snippet-code-css lang-css prettyprint-override"><code>.one {
    height: 495px;
    flex-basis: 50%;
    max-width: 50%;
    min-width: 35%;
    position: relative;
    top: 20px;
    margin-right: 20px;
    margin-left: 10px;
    outline: solid red 1px;
  }
  
  .two {
    height: 210px;
    top: 20px;
    position: relative;
    margin-left: 10px;
    margin-right: 10px;
    flex-basis: 50%;
    max-width: 50%;
    min-width: 15%;
    outline: solid red 1px;
  }
  
  .flex {
    height: 100%;
    width: 100%;
    display: flex;
  }
  
  .Box {
    cursor: pointer;
    width: 85%;
    padding-left: 8px;
  }
  
  .Name {
    margin: 0px;
    width: 85%;
    max-height: 25px;
    font-size: 18px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  
  .Date {
    margin: 0px;
  }
  
  .task {
    width: 100%;
    height: 55px;
    cursor: pointer;
    background-color: white;
    border-top: solid #eaeaea 1px;
    border-bottom: solid #eaeaea 1px;
  }
  
  .Details {
    position: relative;
    top: 10%;
    display: inline-block;
    margin-left: 15px;
    width: 85%;
  }
  
  .three {
    height: 210px;
    top: 20px;
    position: relative;
    margin-left: 10px;
    margin-right: 10px;
    flex-basis: 50%;
    max-width: 50%;
    min-width: 35%;
    outline: solid red 1px;
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"&gt;&lt;/script&gt;
  &lt;div class="flex"&gt;
  
    &lt;div class="one"&gt;
      one
      &lt;div class="task task-container" data-type="yes"&gt;
        &lt;div class="Details"&gt;
          &lt;div class="Box"&gt;
            &lt;p class="Name"&gt;A very long nameeeeeeeeeeeeeeeeeeeeeeeeeeeeemmmmmmmmmmmmmmmmee&lt;/p&gt;
            &lt;p class="Date"&gt;Due: 4/10/2018&lt;/p&gt;
          &lt;/div&gt;
        &lt;/div&gt;
      &lt;/div&gt;
    &lt;/div&gt;
    &lt;div class="two"&gt;
      two
    &lt;/div&gt;
    &lt;div class="three"&gt;
      three
      &lt;div class="task task-container" data-type="yes"&gt;
        &lt;div class="Details"&gt;
          &lt;div class="Box"&gt;
            &lt;p class="Name"&gt;&lt;/p&gt;
            &lt;p class="Date"&gt;Due: 4/10/2018&lt;/p&gt;
          &lt;/div&gt;
        &lt;/div&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  &lt;/div&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>LINK- <a href="https://jsfiddle.net/t29ffzan/35/" rel="nofollow noreferrer">https://jsfiddle.net/t29ffzan/35/</a></p>