I just found out how to hide the scrollbar in Google Chrome, I did it with this code:
::-webkit-scrollbar { display: none; }
The only problem is that this doesn't work on Firefox. I tried many ways to do it but it still doesn't work.
The Best Answer is You can use the scrollbar-width rule. You can scrollbar-width: none; to hide the scrollbar in Firefox and still be able to scroll freely.
To hide the scrollbar and disable scrolling, we can use the CSS overflow property. This property determines what to do with content that extends beyond the boundaries of its container. To prevent scrolling with this property, just apply the rule overflow: hidden to the body (for the entire page) or a container element.
You can use the scrollbar-width
rule. You can scrollbar-width: none;
to hide the scrollbar in Firefox and still be able to scroll freely.
body { scrollbar-width: none; }
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With