From ac09e3851851c27a80e7f283299553127c30a3a0 Mon Sep 17 00:00:00 2001 From: Vladimir Kharlampidi Date: Thu, 12 Aug 2021 12:38:02 +0300 Subject: [PATCH] fix(core): double check for documentElement in smoothScroll detection --- src/shared/get-support.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shared/get-support.js b/src/shared/get-support.js index cbe20a22f..290eaf325 100644 --- a/src/shared/get-support.js +++ b/src/shared/get-support.js @@ -7,7 +7,7 @@ function calcSupport() { const document = getDocument(); return { - smoothScroll: 'scrollBehavior' in document.documentElement.style, + smoothScroll: document.documentElement && 'scrollBehavior' in document.documentElement.style, touch: !!( 'ontouchstart' in window ||