I am making a Rails app, and am trying to achieve a particular functionality relating to Twitter\'s Bootstrap collapse. Bear with me as I explain it.
I currently hav
If you are using Bootstrap 4, and you don't want to change your markup:
var $myGroup = $('#myGroup'); $myGroup.on('show.bs.collapse','.collapse', function() { $myGroup.find('.collapse.show').collapse('hide'); });