How to remove auto slide on Bootstrap Carousel with JavaScript?

Sometimes, we want to remove auto slide on Bootstrap Carousel with JavaScript.

In this article, we’ll look at how to remove auto slide on Bootstrap Carousel with JavaScript.

How to remove auto slide on Bootstrap Carousel with JavaScript?

To remove auto slide on Bootstrap Carousel with JavaScript, we call carousel with an object.

For instance, we write

$(".carousel").carousel({
  interval: false,
});

to call carousel with an object that has interval set to false to disable auto slide on the Bootstrap carousel when creating it.

Conclusion

To remove auto slide on Bootstrap Carousel with JavaScript, we call carousel with an object.