Click event is not working on svg path
<p>Hi i am working on some stuff and i am using svg path but svg's click event not working</p>

<pre><code>  $path.map(function(){
    $(this).mouseenter(function(){
        $count = $path.attr('data-like');
        $('#counter').text($count);
        $('#tool').addClass('active');

    });
    $(this).mousemove(function(e){
        $('#tool').css({'top': e.pageY + -14,'left': e.pageX + -14});
    });
    $(this).mouseleave(function(){
        $('#tool').removeClass('active');
    });
    $(this).click(function(){
        console.log('click');
    });


  });
</code></pre>

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

<p>edit: when i made a mistake in mouseenter function, strangely click function start working.</p>