Search code examples
javascriptjquerymcustomscrollbar

How can i use mCustomScrollbar instead of the default browser scrollbar?


I used this code:

$("body").mCustomScrollbar({
      theme: "3d-thick-dark",
      scrollButtons: { enable: true }
});

mcustomscrollbar work on another elements. but doesn't work on body or html element!


Solution

  • The problem was solved. I just had to use the following code in Css.

    html, body {
      height: 100%;
    }