MCPcopy Create free account
hub / github.com/dailydotdev/apps / cleanup

Function cleanup

packages/shared/src/components/shell/shellMove.ts:117–128  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

115 let arriving: HTMLElement | undefined;
116 const listeners: Array<[RouteEvent, () => void]> = [];
117 const cleanup = () => {
118 window.clearTimeout(timeout);
119 window.clearTimeout(ending);
120 cancelAnimationFrame(frame);
121 listeners.forEach(([name, handler]) => router.events.off(name, handler));
122 leaving.remove();
123 arriving?.remove();
124 delete root.dataset.shellMove;
125 if (active === cleanup) {
126 active = undefined;
127 }
128 };
129 active = cleanup;
130
131 const travel = `${pageDuration}ms var(--shell-ease-travel)`;

Callers 3

setupFunction · 0.50
DeviceFunction · 0.50
useSponsorLogoRatiosFunction · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected