remove TODO type

pull/7324/head
Ivan Hofer 4 years ago
parent c5de00fe82
commit d8f28f8612

@ -1,8 +1,6 @@
import { Readable, Subscriber, Writable } from 'svelte/store';
import { SvelteComponent } from '../index.js';
type TODO<T = any> = T
export function noop() {}
export const identity = <T>(x: T): T => x;
@ -74,7 +72,7 @@ export function subscribe<T, S extends Readable<T>>(store: S, ...callbacks: Arra
return noop;
}
// TODO: `store` does not accept an array of callbacks
const unsub: TODO = store.subscribe(...(callbacks as [TODO]));
const unsub: any = store.subscribe(...(callbacks as [any]));
return unsub.unsubscribe ? () => unsub.unsubscribe() : unsub;
}

Loading…
Cancel
Save