What is the best way to debug jQuery selector? : <pre><code>&lt;div id="chart2Carousel" class="carousel slide" data-ride="carousel"&gt;
    &lt;!-- Wrapper for slides --&gt;
    &lt;div class="carousel-inner"&gt;
        &lt;div class="item active"&gt;&lt;div class="chartjs-size-monitor"&gt;&lt;div class="chartjs-size-monitor-expand"&gt;&lt;div class=""&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="chartjs-size-monitor-shrink"&gt;&lt;div class=""&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;

            &lt;canvas width="683" height="341" id="chart2" class="chartjs-render-monitor" style="display: block; width: 683px; height: 341px;"&gt;&lt;/canvas&gt;

        &lt;/div&gt;
    &lt;/div&gt;

    &lt;!-- Left and right controls --&gt;
    &lt;a class="left carousel-control" href="#chart2Carousel" data-slide="prev"&gt;
        &lt;span class="fa fa-chevron-left"&gt;&lt;/span&gt;
        &lt;span class="sr-only"&gt;Previous&lt;/span&gt;
    &lt;/a&gt;
    &lt;a class="right carousel-control" href="#chart2Carousel" data-slide="next" style="display: block;"&gt;
        &lt;span class="fa fa-chevron-right"&gt;&lt;/span&gt;
        &lt;span class="sr-only"&gt;Next&lt;/span&gt;
    &lt;/a&gt;
&lt;/div&gt;
</code></pre>

<p>I've tried </p>

<p>//selectedChart = chart2 </p>

<pre><code>$('#' + selectedChart).closest(".carousel-inner").find(".left.carousel-control").hide();
</code></pre>

<p>Why does it not working ? </p>

<p><strong>What is the best way to debug jQuery selector ?</strong> </p>
