stickybits
stickybits copied to clipboard
useStickyClasses option adds classes early
Bug
When using sticky classes, they are triggered on .js-stickybit-parent
rather than the top of the activated element itself. If there are elements within .js-stickybit-parent
and above the activated element , the classes are added before the element becomes sticky. see the video link attached.
Steps to reproduce the behavior:
- set
useStickyClasses: true
- add html to the element parent.
- Scroll down and notice the
.js-is-sticky
class is added when.js-stickybit-parent
hits the top of the viewport rather than when the element becomes sticky.
Expected behavior classes are added when the element becomes sticky
Bug Video https://www.loom.com/share/9c6870eceaf147f29e5298945dae3f14
Hey, thanks for filing an issue with Stickybits' first issue
Hello. This problem is still actual, awaiting fix, thanks
Experiencing the same issue. Is there any workaround method? Thanks.
Have also run into this, haven't figured a workaround as yet