type Handler = ({ req, res }: { req: T1; res: T2 }) => any; // globby needs setImmediate // eslint-disable-next-line @typescript-eslint/ban-ts-comment // @ts-expect-error global.setImmediate = setTimeout; // eslint-disable-next-line @typescript-eslint/ban-ts-comment // @ts-expect-error global.clearImmediate = clearTimeout; export const flattenFuncArgs = (handler: Handler) => (req: T1, res: T2) => handler({ req, res }); export const INTROSPECTION_ROUTE_PATH = '/__introspection__';