diff --git a/src/js/plugins/navscroll.js b/src/js/plugins/navscroll.js index 795b07741f..e5532320f0 100644 --- a/src/js/plugins/navscroll.js +++ b/src/js/plugins/navscroll.js @@ -244,11 +244,10 @@ class NavScroll extends BaseComponent { * ------------------------------------------------------------------------ */ -onDocumentScroll(() => { - const navs = SelectorEngine.find(SELECTOR_NAVSCROLL) - navs.map((nav) => { - NavScroll.getOrCreateInstance(nav) - }) +const navs = SelectorEngine.find(SELECTOR_NAVSCROLL) +navs.map((nav) => { + NavScroll.getOrCreateInstance(nav) }) + export default NavScroll