title: Click event in bootstrap 3 tabs
body: <p>I have the following HTML:</p>
  
  <pre><code>&lt;div id="channels"&gt;
      &lt;ul class="nav nav-tabs" id="ul-channels"&gt;
          &lt;li class="channel" data-roomid="lobby"&gt;&lt;a class="link-channel" href="#lobby" data-toggle="tab"&gt;lobby&lt;/a&gt;&lt;/li&gt;
          &lt;li class="channel active selected" data-roomid="test"&gt;&lt;a class="link-channel" href="#test" data-toggle="tab"&gt;test&lt;/a&gt;&lt;/li&gt;
      &lt;/ul&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>I need an event that occurs when switching tabs. Like this:</p>
  
  <pre><code>$('.nav-tabs a').click(function (e) {
      alert("Q");
  });
  </code></pre>
  
  <p>I tried a lot of options, but I had no success. I will appreciate any help.</p>