No stackoverflow mentioned that it’s not possible to use any of these methods on a codepen.io page.
I’m still trying to find an alternative to use on codepen (to reload my codepen page)
Thanks
Considering it’s a React app I don’t see why they would refresh the page. The header changes based on the scroll position but that has nothing to do with a page refresh.
Reloading the page every time the user scrolls to the top also seems like an odd/annoying UX decision and is likely not what you want.
What exactly are you trying to achieve by reloading the page?
Anyway, if you need the page reload use a different site like Stackblitz or a host like Netlify instead of Codepen.
Yes, the header needs to reload to the background image?
When a user scrolls down the header becomes white, and then when a user scrolls up all the way to the top it becomes the regular background again.
It’s been more than a year since I dealt with JS/Jquery so considering that I’m doing pretty well.