Library not getting attached properly after Ajax call

Created on 23 September 2022, almost 2 years ago
Updated 23 June 2023, about 1 year ago

Problem/Motivation

Whenever the view is rendered by a ajax request and if that view uses infinite scroll as pager options then its not adding its dependent library viz views_infinite_scroll/views-infinite-scroll.

Steps to reproduce

  • Create a view block which has exposed grouped filters.
  • Enable ajax and add infinite scroll pager to it.
  • Create default grouped filter in such a way that infinite scroll pager's item limit should be more than total items to be render under that filter.
  • Add this view block on a page and check it.
  • By default when the page opens there would be no requirement of infinite scroll so it won't attach its library
  • Change the filter value so that infinite scroll would be required.
  • After updating the view we see that load more is not working anymore. In console an error is thrown
  • Uncaught TypeError: $wrapper[method] is not a function

Proposed resolution

Attach the library if the pager plugin option is set to infinite_scroll.

🐛 Bug report
Status

Postponed: needs info

Version

1.9

Component

Code

Created by

🇮🇳India Hemuvyas97

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • 🇩🇪Germany Anybody Porta Westfalica

    Is this still an issue with 2.0.x? If yes, please update the version and set the status active again with clear steps or (best) with a test showing what's broken.

    2.0.x is the active development branch.

    If nobody replies, we should assume this is fixed and close this issue outdated.

    Thanks!

Production build 0.69.0 2024