Toggle the button

How will you write a function that will execute when a certain button with collapse call having a id as navBar has been made visible to the user?

Options

How will you write a function that will execute when a certain button with collapse call having a id as navBar has been made visible to the user?

Options
1.$('#navBar').on('shown.bs.collapse', function () { // Your Code }
2.$('#navBar').on('show.bs.collapse', function () { // Your Code }

3.$('#navBar').on('toggle.bs.collapse', function () { // Your Code }
4.$('#navBar').collapse({ // Your Code }

Related Posts