addEventListeners piling up
Michael Redwine last edited by
So perhaps I am doing something wrong. I am observing that eventListeners are piling up. Here is my situation. I tap a button, which causes a pushPage to occur. In the new page, add an eventListener. Later, the page gets popped. If I pushPage to the page again, an additional eventListener is created. The old event listener isn’t removed when a page is removed from the DOM. I see this using Chrome Dev tools. My question: should Onsen do this for me, or am I expected to manage this myself?
I tried out your scenario in the playground but I was unable to replicate the problem. For me, the event listener is being removed on
Could you please provide a working example through https://onsen.io/playground ? From there you can export it to codepen.
Also what version of Onsen UI are you using?
diogeneshamilton last edited by