We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fa87bdc commit bd68002Copy full SHA for bd68002
src/index.ts
@@ -7,7 +7,7 @@ export interface ScrollbarWidth {
7
export const scrollbarWidth: ScrollbarWidth = (force?: boolean): number | undefined => {
8
// safety check for SSR
9
/* istanbul ignore next */
10
- if (!document) {
+ if (typeof document === 'undefined') {
11
return 0;
12
}
13
0 commit comments