# api.onPageChange werkt niet met eindeloos scrollen

**URL:** <https://meta.discourse.org/t/api-onpagechange-not-working-with-endless-scroll/179636>\
**Category:** Development\
**Created:** [14 februari 2021 om 07:16 UTC](https://meta.discourse.org/t/api-onpagechange-not-working-with-endless-scroll/179636 "2021-02-14T07:16:17Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![AstonJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/astonj/32/215041_2.png) [@AstonJ](https://meta.discourse.org/u/AstonJ)\
**Post date:** [14 februari 2021 om 22:05 UTC](https://meta.discourse.org/t/api-onpagechange-not-working-with-endless-scroll/179636/3 "2021-02-14T22:05:00Z")

</div>

Thanks Robert - I was hoping a something simple would suffice! 🙈

It’s been a while since I read the plugin guide but from memory it goes something like this?

- rails g plugin NAME
- locate the file you want to change
- copy it into the same directory in your plugin
- make your changes

However this is not working for me.

Editing this file directly (on line 29): [discourse/app/assets/javascripts/discourse/app/lib/render-tag.js at bbe5d8d5cf1220165842985c0e2cd4c454d501cd · discourse/discourse · GitHub](https://github.com/discourse/discourse/blob/bbe5d8d5cf1220165842985c0e2cd4c454d501cd/app/assets/javascripts/discourse/app/lib/render-tag.js) has the desired effect, but when I duplicate the file in the following location it has no impact `plugins/my-plugin/app/assets/javascripts/discourse/app/lib/render-tag.js`.

Any ideas what I’m doing wrong? Has something changed since I read the guides perhaps? (For some reason I thought it was as simple as overriding files to change small things like this).

---

_[View the full topic](https://meta.discourse.org/t/api-onpagechange-not-working-with-endless-scroll/179636)._
