Created by: sehyun-hwang
When getBoundingClientRect
method is used and when page is refreshed to a scroll position that is not at the top but below it, clicking a nav button will result in scrolling to wrong position. I was able to fix this giving offset of window.pageYOffset