---
title: "Discussion on \"Better scrolling through modern CSS\" | Hashnode"
description: "Discussion on \"Better scrolling through modern CSS\". There's more to scrollbars than you might expect"
url: "https://hashnode.com/posts/better-scrolling-through-modern-css/62a3ec7ba2c282d2d837800e"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Better scrolling through modern CSS](https://blog.mayank.co/better-scrolling-through-modern-css?utm_source=hashnode&utm_medium=feed)

There's more to scrollbars than you might expect

Jun 11, 2022 · 8 min read · blog.mayank.co  
Updated Oct 14, 2022  
Read the article

-   [#css](https://hashnode.com/tag/css)
-   [#web-development](https://hashnode.com/tag/web-development)

## Written by

[Mayank](https://hashnode.com/@mayxnk)

@mayxnk

  
[View profile](https://hashnode.com/@mayxnk)

frontend stuff

## Responses 8

Markdown supported · ⌘↵ to post

[Šime Vidas](https://hashnode.com/@Zagrebian)

[Aug 16, 2022](https://hashnode.com/posts/better-scrolling-through-modern-css/62a3ec7ba2c282d2d837800e/comment/62fb8257c0004ed752ad9b2f)

In the “Preventing layout shift” section, it should be noted that the issue is limited to classic scrollbars (Windows 10). All other major platforms have overlay scrollbars, which don’t have gutters that can appear and disappear.

[Jay](https://hashnode.com/@Jay13)

[Jul 29, 2022](https://hashnode.com/posts/better-scrolling-through-modern-css/62a3ec7ba2c282d2d837800e/comment/62e3d20e430bd1d04a83e4ea)

Very informative. One of those things you need to know, but don't realize it. Thanks

[yinon](https://hashnode.com/@yinon)

[Jun 27, 2022](https://hashnode.com/posts/better-scrolling-through-modern-css/62a3ec7ba2c282d2d837800e/comment/62b9de30f2e6c7d70c1242f8)

Thanks for an illuminating piece. funny enough, `overscroll-behavior: contain` will not apply or affect an element without enough content to apply a scrollbar. so no overscroll-behavior if no overflow content

[Konstantin BIFERT](https://hashnode.com/@kissu)

[Jun 19, 2022](https://hashnode.com/posts/better-scrolling-through-modern-css/62a3ec7ba2c282d2d837800e/comment/62af0d9cd8afe74aa51fcae5)

Since you were speaking about MacOS and Windows, adding Linux would have been nice too.

[brucce tran](https://hashnode.com/@bruccetran)

[Jun 13, 2022](https://hashnode.com/posts/better-scrolling-through-modern-css/62a3ec7ba2c282d2d837800e/comment/62a6d8c4165482d2b3ef0179)

Extremely useful information. I am building my own [Penalty Shooters 2](https://penaltyshooters2.com/) website. But what I learn from blogs like this makes my job a lot easier. You can check it out and give me more ideas about the layout, as well as the game genres. Nice to connect with you.

[Shubham Kumar Singh](https://hashnode.com/@shubhamsinghbundela)

[Jun 12, 2022](https://hashnode.com/posts/better-scrolling-through-modern-css/62a3ec7ba2c282d2d837800e/comment/62a55e0b165482d2b3eecc6d)

Thanku [Mayank](https://hashnode.com/@mayxnk)

[Tejinder Sharma](https://hashnode.com/@Tejinder)

[Jun 11, 2022](https://hashnode.com/posts/better-scrolling-through-modern-css/62a3ec7ba2c282d2d837800e/comment/62a49295165482d2b3eeba3f)

Nicely written article.
