优化
This commit is contained in:
5
client/shared/types.ts
Normal file
5
client/shared/types.ts
Normal file
@@ -0,0 +1,5 @@
|
||||
export type PromiseType<P extends Promise<any>> = P extends Promise<infer T>
|
||||
? T
|
||||
: never;
|
||||
|
||||
export type FunctionReturningPromise = (...args: any[]) => Promise<any>;
|
||||
Reference in New Issue
Block a user