$(window).scroll(…) is running even if the template is destroyed in meteor
问题 I have two separate template and in both template(rendered) i am doing $(window).scroll() but however go to one template another, the $(window).scroll() is running from both, previous as well as current template. Code Snippets as below: dashboard1.js Template.dashboard1.rendered = function(){ $(window).scroll(function() { console.log('dashboard1 scroll'); //... doing pagination and sticky element for dashboard1 }); } Template.dashboard1.destroyed = function(){ console.log('dashboard1