alvarotrigo / react-fullpage

Official React.js wrapper for fullPage.js https://alvarotrigo.com/react-fullpage/
GNU General Public License v3.0
1.28k stars 179 forks source link

getScrollY() is not a function #417

Closed RexHung0302 closed 1 year ago

RexHung0302 commented 1 year ago

Description

I use getScrollY() and getScrollX(), get this is not a function.

can find this api at doc where https://alvarotrigo.com/fullPage/docs/#getscrolly--getscrollx

Steps to reproduce it

  1. I use https://alvarotrigo.com/react-fullpage/
  2. useEffect(() => {
    if (!window.fullpage_api) return;
    console.log(window.fullpage_api.getScrollY()); // This was failed
    }, []);

Versions

@fullpage/react-fullpage": "0.1.22

alvarotrigo commented 1 year ago

Versions

@fullpage/react-fullpage": "0.1.22

Update to the latest version 0.1.40 ;)

RexHung0302 commented 1 year ago

Thank for reply~