Using infinite scroll outside router component

Hello,
I have tried using infinite scroll outside router component with no luck. My problem is I can’t use the @infinite event on regular vanilla code.
Is there a way or should I stop trying?
Best regards;

Can you provide a code sample? The infinite event is designed to work with standard code. Infinite Scroll | Framework7 Documentation

1 Like

That’s what’s mentioned in the docs. How can I watch for the @infinite=${loadMore} event? I have tried oninfinite and other methods with no luck.

Use the Dom7 .on event to listen for infinite.

$$('.infinite-scroll-content').on('infinite', function (e) {
  // Code to execute when 'infinite' has fired
});

You can see a live example in this JS Fiddle: https://jsfiddle.net/kerrydp/nr8fsq9o/52/

1 Like