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 20e6246 commit 59d28c2Copy full SHA for 59d28c2
lib/VirtualList.js
@@ -70,7 +70,7 @@ var VirtualList = function VirtualList(options) {
70
_this.refreshState = _this.refreshState.bind(_this);
71
72
// if requestAnimationFrame is available, use it to throttle refreshState
73
- if (window && 'requestAnimationFrame' in window) {
+ if (typeof window !== 'undefined' && 'requestAnimationFrame' in window) {
74
_this.refreshState = (0, _throttleWithRAF2.default)(_this.refreshState);
75
}
76
return _this;
0 commit comments