mirror of
https://github.com/overleaf/overleaf.git
synced 2024-12-12 08:37:33 -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))
|
||
|
}
|