Untitled

mail@pastecode.io avatar
unknown
javascript
2 months ago
183 B
2
Indexable
Never
$('tab').click(function() {
    const index = $(this).index();

    $('tab, content').removeClass('active');
    $(`tab:eq(${index}), content:eq${index}`).addClass('active');
});
Leave a Comment