mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-07 20:31:06 -05:00
7 lines
174 B
TypeScript
7 lines
174 B
TypeScript
|
export function callFnsInSequence<
|
||
|
Args,
|
||
|
Fn extends ((...args: Args[]) => void) | void
|
||
|
>(...fns: Fn[]) {
|
||
|
return (...args: Args[]) => fns.forEach(fn => fn?.(...args))
|
||
|
}
|