This repository has been archived on 2024-04-27. You can view files and clone it, but cannot push or open issues or pull requests.
2023-06-19 15:01:37 +03:00
|
|
|
# get-scrollbar-width
|
|
|
|
|
2024-02-27 11:14:03 +03:00
|
|
|
Get window scrollbar width (if present):
|
|
|
|
|
2023-06-19 15:01:37 +03:00
|
|
|
```js
|
|
|
|
import getScrollbarWidth from '@advdominion/get-scrollbar-width';
|
|
|
|
|
|
|
|
console.log(getScrollbarWidth());
|
|
|
|
```
|
2024-02-27 11:14:03 +03:00
|
|
|
|
|
|
|
Get system scrollbar width:
|
|
|
|
|
|
|
|
```js
|
|
|
|
import getScrollbarWidth from '@advdominion/get-scrollbar-width';
|
|
|
|
|
|
|
|
console.log(getScrollbarWidth(false));
|
|
|
|
```
|