BigW Consortium Gitlab

Commit cd111ffa by Regis

anon callbacks since intervals removed in function prior - [ci skip]

parent d6061b73
......@@ -45,7 +45,6 @@
const startTimeLoops = () => {
this.timeLoopInterval = setInterval(() => {
console.log('TIME LOOP');
this.$children
.filter(e => e.$options._componentTag === 'time-ago')
.forEach(e => e.changeTime());
......@@ -64,10 +63,10 @@
const removeAll = () => {
removeTimeIntervals();
window.removeEventListener('beforeunload', removeTimeIntervals);
window.removeEventListener('focus', startIntervalLoops);
window.removeEventListener('blur', removeTimeIntervals);
document.removeEventListener('page:fetch', removeTimeIntervals);
window.removeEventListener('beforeunload', () => {});
window.removeEventListener('focus', () => {});
window.removeEventListener('blur', () => {});
document.removeEventListener('page:fetch', () => {});
};
window.addEventListener('beforeunload', removeTimeIntervals);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment